51df4c
diff -up rpcbind-1.2.5/src/rpcbind.c.orig rpcbind-1.2.5/src/rpcbind.c
51df4c
--- rpcbind-1.2.5/src/rpcbind.c.orig	2022-08-04 15:56:21.398070276 -0400
51df4c
+++ rpcbind-1.2.5/src/rpcbind.c	2022-08-04 15:56:57.255699229 -0400
51df4c
@@ -563,8 +563,10 @@ init_transport(struct netconfig *nconf)
51df4c
 				syslog(LOG_ERR, "cannot bind %s on %s: %m",
51df4c
 					(hosts[nhostsbak] == NULL) ? "*" :
51df4c
 					hosts[nhostsbak], nconf->nc_netid);
51df4c
-				if (res != NULL)
51df4c
+				if (res != NULL) {
51df4c
 					freeaddrinfo(res);
51df4c
+					res = NULL;
51df4c
+				}
51df4c
 				continue;
51df4c
 			} else
51df4c
 				checkbind++;