fix several memory leaks in omapi (#978420)
- remove send_release.patch (#979510)
This commit is contained in:
parent
63132f167a
commit
2a156e969f
@ -1,23 +0,0 @@
|
|||||||
diff -up dhcp-4.2.4b1/client/dhclient.c.send_release dhcp-4.2.4b1/client/dhclient.c
|
|
||||||
--- dhcp-4.2.4b1/client/dhclient.c.send_release 2012-04-16 17:48:52.000000000 +0200
|
|
||||||
+++ dhcp-4.2.4b1/client/dhclient.c 2012-04-16 17:50:44.357396720 +0200
|
|
||||||
@@ -2764,8 +2764,8 @@ void send_release (cpp)
|
|
||||||
inet_ntoa (destination.sin_addr),
|
|
||||||
ntohs (destination.sin_port), client -> xid);
|
|
||||||
|
|
||||||
- if (fallback_interface) {
|
|
||||||
- result = send_packet(fallback_interface, NULL, &client->packet,
|
|
||||||
+ if (client -> interface) {
|
|
||||||
+ result = send_packet(client -> interface, NULL, &client->packet,
|
|
||||||
client->packet_length, from, &destination,
|
|
||||||
NULL);
|
|
||||||
if (result < 0) {
|
|
||||||
@@ -2776,7 +2776,7 @@ void send_release (cpp)
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
/* Send out a packet. */
|
|
||||||
- result = send_packet(client->interface, NULL, &client->packet,
|
|
||||||
+ result = send_packet(fallback_interface, NULL, &client->packet,
|
|
||||||
client->packet_length, from, &destination,
|
|
||||||
NULL);
|
|
||||||
if (result < 0) {
|
|
40
dhcp-4.2.5-omapi-leak.patch
Normal file
40
dhcp-4.2.5-omapi-leak.patch
Normal file
@ -0,0 +1,40 @@
|
|||||||
|
diff -up dhcp-4.2.5/common/comapi.c.leak dhcp-4.2.5/common/comapi.c
|
||||||
|
diff -up dhcp-4.2.5/server/db.c.leak dhcp-4.2.5/server/db.c
|
||||||
|
--- dhcp-4.2.5/server/db.c.leak 2013-07-02 13:34:56.000000000 +0200
|
||||||
|
+++ dhcp-4.2.5/server/db.c 2013-07-02 13:37:06.335729135 +0200
|
||||||
|
@@ -414,6 +414,7 @@ int write_host (host)
|
||||||
|
fputc (';', db_file);
|
||||||
|
if (errno)
|
||||||
|
++errors;
|
||||||
|
+ data_string_forget (&ip_addrs, MDL);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (host -> named_group) {
|
||||||
|
diff -up dhcp-4.2.5/server/omapi.c.leak dhcp-4.2.5/server/omapi.c
|
||||||
|
--- dhcp-4.2.5/server/omapi.c.leak 2013-01-03 01:02:25.000000000 +0100
|
||||||
|
+++ dhcp-4.2.5/server/omapi.c 2013-07-02 13:41:05.701429114 +0200
|
||||||
|
@@ -1179,8 +1179,6 @@ isc_result_t dhcp_host_destroy (omapi_ob
|
||||||
|
if (h -> type != dhcp_type_host)
|
||||||
|
return DHCP_R_INVALIDARG;
|
||||||
|
|
||||||
|
-#if defined (DEBUG_MEMORY_LEAKAGE) || \
|
||||||
|
- defined (DEBUG_MEMORY_LEAKAGE_ON_EXIT)
|
||||||
|
struct host_decl *host = (struct host_decl *)h;
|
||||||
|
if (host -> n_ipaddr)
|
||||||
|
host_dereference (&host -> n_ipaddr, file, line);
|
||||||
|
@@ -1199,7 +1197,6 @@ isc_result_t dhcp_host_destroy (omapi_ob
|
||||||
|
omapi_object_dereference ((omapi_object_t **)
|
||||||
|
&host -> named_group, file, line);
|
||||||
|
data_string_forget (&host -> auth_key_id, file, line);
|
||||||
|
-#endif
|
||||||
|
|
||||||
|
return ISC_R_SUCCESS;
|
||||||
|
}
|
||||||
|
@@ -1285,6 +1282,7 @@ isc_result_t dhcp_host_stuff_values (oma
|
||||||
|
ip_addrs.data, ip_addrs.len);
|
||||||
|
if (status != ISC_R_SUCCESS)
|
||||||
|
return status;
|
||||||
|
+ data_string_forget (&ip_addrs, MDL);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (host -> client_identifier.len) {
|
14
dhcp.spec
14
dhcp.spec
@ -18,7 +18,7 @@
|
|||||||
Summary: Dynamic host configuration protocol software
|
Summary: Dynamic host configuration protocol software
|
||||||
Name: dhcp
|
Name: dhcp
|
||||||
Version: 4.2.5
|
Version: 4.2.5
|
||||||
Release: 14%{?dist}
|
Release: 15%{?dist}
|
||||||
# NEVER CHANGE THE EPOCH on this package. The previous maintainer (prior to
|
# NEVER CHANGE THE EPOCH on this package. The previous maintainer (prior to
|
||||||
# dcantrell maintaining the package) made incorrect use of the epoch and
|
# dcantrell maintaining the package) made incorrect use of the epoch and
|
||||||
# that's why it is at 12 now. It should have never been used, but it was.
|
# that's why it is at 12 now. It should have never been used, but it was.
|
||||||
@ -70,7 +70,7 @@ Patch36: dhcp-4.2.5-systemtap.patch
|
|||||||
Patch37: dhcp-4.2.3-dhclient-decline-onetry.patch
|
Patch37: dhcp-4.2.3-dhclient-decline-onetry.patch
|
||||||
Patch38: dhcp-4.2.3-P2-log_perror.patch
|
Patch38: dhcp-4.2.3-P2-log_perror.patch
|
||||||
Patch39: dhcp-4.2.4-getifaddrs.patch
|
Patch39: dhcp-4.2.4-getifaddrs.patch
|
||||||
Patch40: dhcp-4.2.4-send_release.patch
|
Patch40: dhcp-4.2.5-omapi-leak.patch
|
||||||
Patch41: dhcp-4.2.5-rfc5970-dhcpv6-options-for-network-boot.patch
|
Patch41: dhcp-4.2.5-rfc5970-dhcpv6-options-for-network-boot.patch
|
||||||
Patch42: dhcp-4.2.4-failOverPeer.patch
|
Patch42: dhcp-4.2.4-failOverPeer.patch
|
||||||
Patch43: dhcp-4.2.5b1-atf-pkgconfig.patch
|
Patch43: dhcp-4.2.5b1-atf-pkgconfig.patch
|
||||||
@ -307,9 +307,9 @@ rm -rf includes/isc-dhcp
|
|||||||
# (Submitted to dhcp-bugs@isc.org - [ISC-Bugs #28761])
|
# (Submitted to dhcp-bugs@isc.org - [ISC-Bugs #28761])
|
||||||
%patch39 -p1 -b .getifaddrs
|
%patch39 -p1 -b .getifaddrs
|
||||||
|
|
||||||
# Don't use fallback_interface when releasing lease (#800561)
|
# Fix several memory leaks in omapi (#978420)
|
||||||
# (Submitted to dhcp-bugs@isc.org - [ISC-Bugs #30544])
|
# (Submitted to dhcp-bugs@isc.org - [ISC-Bugs #33990])
|
||||||
%patch40 -p1 -b .send_release
|
%patch40 -p1 -b .leak
|
||||||
|
|
||||||
# RFC5970 - DHCPv6 Options for Network Boot (#798735)
|
# RFC5970 - DHCPv6 Options for Network Boot (#798735)
|
||||||
%patch41 -p1 -b .rfc5970
|
%patch41 -p1 -b .rfc5970
|
||||||
@ -609,6 +609,10 @@ done
|
|||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Tue Jul 02 2013 Jiri Popelka <jpopelka@redhat.com> - 12:4.2.5-15
|
||||||
|
- fix several memory leaks in omapi (#978420)
|
||||||
|
- remove send_release.patch (#979510)
|
||||||
|
|
||||||
* Tue Jun 18 2013 Jiri Popelka <jpopelka@redhat.com> - 12:4.2.5-14
|
* Tue Jun 18 2013 Jiri Popelka <jpopelka@redhat.com> - 12:4.2.5-14
|
||||||
- rebuilt against bind once more
|
- rebuilt against bind once more
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user