]> git.ipfire.org Git - thirdparty/krb5.git/commit
Fix bugs in bindresvport_sa() changes 165/head
authorTom Yu <tlyu@mit.edu>
Wed, 2 Jul 2014 20:13:23 +0000 (16:13 -0400)
committerTom Yu <tlyu@mit.edu>
Wed, 2 Jul 2014 21:04:37 +0000 (17:04 -0400)
commit158a551b14b017d232066c4a053dc608d87fa172
treed946d4f56bf33b0a1cbd317fe54a42669e840802
parent4bd50f73c80a86852ec0879abdf52202be40892b
Fix bugs in bindresvport_sa() changes

In svctcp_create() and svcudp_bufcreate(), set sa->sa_len on platforms
where that field exists, so that a subsequent call to socklen() will
return the correct result.

To make the code more self-evidently correct, zero the entire struct
sockaddr_storage object, using the memset(&ss, 0, sizeof(ss)) idiom.

ticket: 7935
src/lib/rpc/svc_tcp.c
src/lib/rpc/svc_udp.c