summaryrefslogtreecommitdiff
path: root/ext/socket/socket.c
diff options
context:
space:
mode:
authoreban <eban@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2002-04-02 06:12:04 +0000
committereban <eban@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2002-04-02 06:12:04 +0000
commit1cfece051cc64106c5ce18dfa75496633ac97069 (patch)
tree2df29ec2fcc9ad1d821090e7d359e90af1a7083e /ext/socket/socket.c
parentedf4c88f796a521c45318a6b7011f8af0f6d5733 (diff)
* ext/socket/socket.c (sock_addrinfo): should clear addrinfo hints.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2319 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/socket/socket.c')
-rw-r--r--ext/socket/socket.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/ext/socket/socket.c b/ext/socket/socket.c
index cc76bec78c..9a64399637 100644
--- a/ext/socket/socket.c
+++ b/ext/socket/socket.c
@@ -599,6 +599,7 @@ sock_addrinfo(host, port, socktype, flags)
}
else {
hintsp = &hints;
+ MEMZERO(&hints, struct addrinfo, 1);
hints.ai_family = PF_UNSPEC;
hints.ai_protocol = 0;
hints.ai_socktype = socktype;