diff --git a/src/cares_wrap.cc b/src/cares_wrap.cc index aeb525b33e7efa..6c6fca53312158 100644 --- a/src/cares_wrap.cc +++ b/src/cares_wrap.cc @@ -1969,7 +1969,7 @@ void GetAddrInfo(const FunctionCallbackInfo& args) { args[4]->IsTrue()); struct addrinfo hints; - memset(&hints, 0, sizeof(struct addrinfo)); + memset(&hints, 0, sizeof(hints)); hints.ai_family = family; hints.ai_socktype = SOCK_STREAM; hints.ai_flags = flags;