diff options
author | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2011-03-26 06:16:42 +0000 |
---|---|---|
committer | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2011-03-26 06:16:42 +0000 |
commit | c65953cd0303d6c3315376f228c2ac20a8ad0135 (patch) | |
tree | 708e1331d8b93e64cd8743ed0eaaa2598dd46844 /ext/socket | |
parent | 5f969a9d17d6762598a2cff820808acf25012d6d (diff) | |
download | ruby-c65953cd0303d6c3315376f228c2ac20a8ad0135.tar.gz |
* ext/socket/getaddrinfo.c: parenthesize macro arguments.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31185 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/socket')
-rw-r--r-- | ext/socket/getaddrinfo.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/socket/getaddrinfo.c b/ext/socket/getaddrinfo.c index 3382f00e52..aa966b3c52 100644 --- a/ext/socket/getaddrinfo.c +++ b/ext/socket/getaddrinfo.c @@ -182,12 +182,12 @@ if (pai->ai_flags & AI_CANONNAME) {\ error = EAI_MEMORY;\ goto free;\ }\ - memcpy(ai, pai, sizeof(struct addrinfo));\ + memcpy((ai), pai, sizeof(struct addrinfo));\ (ai)->ai_addr = (struct sockaddr *)((ai) + 1);\ memset((ai)->ai_addr, 0, (afd)->a_socklen);\ SET_SA_LEN((ai)->ai_addr, (ai)->ai_addrlen = (afd)->a_socklen);\ (ai)->ai_addr->sa_family = (ai)->ai_family = (afd)->a_af;\ - ((struct sockinet *)(ai)->ai_addr)->si_port = port;\ + ((struct sockinet *)(ai)->ai_addr)->si_port = (port);\ p = (char *)((ai)->ai_addr);\ memcpy(p + (afd)->a_off, (addr), (afd)->a_addrlen);\ } |