appl: Fix warnings in test utils

This commit is contained in:
Nicolas Williams
2022-12-30 16:39:49 -06:00
parent a791f45e62
commit 0bedcc5c62
2 changed files with 7 additions and 0 deletions

View File

@@ -192,6 +192,9 @@ proto (int sock, const char *service)
gss_OID mech_oid;
char *mech, *p;
memset(&remote, 0, sizeof(remote));
local = remote;
addrlen = sizeof(local);
if (getsockname (sock, (struct sockaddr *)&local, &addrlen) < 0
|| addrlen != sizeof(local))