mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
Remember to zero sockaddr_in struct before calling uaddr_to_sockaddr() to
populate it. Not doing this can result in a garbage sockaddr_in, which will cause connect() to block inside clnttcp_create().
This commit is contained in:
parent
f2305d469b
commit
c88fdb1d1d
1 changed files with 1 additions and 0 deletions
|
|
@ -323,6 +323,7 @@ __rpc_get_time_offset(td, srv, thost, uaddr, netid)
|
|||
sprintf(ipuaddr, "%d.%d.%d.%d.0.111", a1, a2, a3, a4);
|
||||
useua = &ipuaddr[0];
|
||||
|
||||
bzero((char *)&sin, sizeof(sin));
|
||||
if (uaddr_to_sockaddr(useua, &sin)) {
|
||||
msg("unable to translate uaddr to sockaddr.");
|
||||
if (needfree)
|
||||
|
|
|
|||
Loading…
Reference in a new issue