remove memset as VERSION_INFO and HOST_INFO are cleared by constructors

Signed-off-by: Biswapriyo Nath <nathbappai@gmail.com>
This commit is contained in:
Biswapriyo Nath 2020-06-27 12:53:58 +05:30
parent 68599941ac
commit f56e7d8824
2 changed files with 0 additions and 2 deletions

View File

@ -431,7 +431,6 @@ int main(int argc, char** argv) {
}
} else if (!strcmp(cmd, "--set_host_info")) {
HOST_INFO h;
memset(static_cast<void*>(&h), 0, sizeof(h));
char* pn = next_arg(argc, argv, i);
safe_strcpy(h.product_name, pn);
retval = rpc.set_host_info(h);

View File

@ -1476,7 +1476,6 @@ int RPC_CLIENT::exchange_versions(string client_name, VERSION_INFO& server) {
retval = rpc.do_rpc(buf);
if (!retval) {
memset(static_cast<void*>(&server), 0, sizeof(server));
while (rpc.fin.fgets(buf, 256)) {
if (match_tag(buf, "</server_version>")) break;
else if (parse_int(buf, "<major>", server.major)) continue;