[Linux-ha-dev] another minor patch to udp.c

Chris Wright chris at wirex.com
Fri Dec 29 16:13:27 MST 2000


While reading udp.c (heartbeat-0.4.8i) I found another fairly minor/nitpicky
item:

after creating a new_ip_interface (which mallocs both the ip_private
struct and a char buffer, interface, in the struct), if something goes
wrong the struct is free'd but the char buffer isn't.

-chris
-------------- next part --------------
--- heartbeat-0.4.8i/heartbeat/udp.c-orig	Fri Dec 29 11:15:01 2000
+++ heartbeat-0.4.8i/heartbeat/udp.c	Fri Dec 29 15:10:23 2000
@@ -147,6 +147,7 @@
 		ret->name = name;
 
 	}else{
+		ha_free(ipi->interface);
 		ha_free(ipi);
 	}
 	return(ret);


More information about the Linux-HA-Dev mailing list