diff options
author | tonnerre <tonnerre@pkgsrc.org> | 2008-06-08 14:08:47 +0000 |
---|---|---|
committer | tonnerre <tonnerre@pkgsrc.org> | 2008-06-08 14:08:47 +0000 |
commit | 3c082a0693fe9cd1cf9919b9c36d092b4449ae46 (patch) | |
tree | ac0f7ab7b6cd4065bfe2cb0530c8589b8ca99a9a /net/nagios-plugins | |
parent | 27fb293d91d31461b8602884eb8ffb1f90c555a7 (diff) | |
download | pkgsrc-3c082a0693fe9cd1cf9919b9c36d092b4449ae46.tar.gz |
Remove some broken malloc logic from the nagios-plugins library.
Discovered and patch provided by Wolfgang Solfrank.
Diffstat (limited to 'net/nagios-plugins')
-rw-r--r-- | net/nagios-plugins/Makefile | 3 | ||||
-rw-r--r-- | net/nagios-plugins/distinfo | 3 | ||||
-rw-r--r-- | net/nagios-plugins/patches/patch-aa | 26 |
3 files changed, 30 insertions, 2 deletions
diff --git a/net/nagios-plugins/Makefile b/net/nagios-plugins/Makefile index be4ebf43243..4fba6cc09ba 100644 --- a/net/nagios-plugins/Makefile +++ b/net/nagios-plugins/Makefile @@ -1,9 +1,10 @@ -# $NetBSD: Makefile,v 1.14 2008/05/27 21:22:03 tonnerre Exp $ +# $NetBSD: Makefile,v 1.15 2008/06/08 14:08:47 tonnerre Exp $ # CATEGORIES= net sysutils MAINTAINER= tonnerre@NetBSD.org +PKGREVISION= 1 HOMEPAGE= http://sourceforge.net/projects/nagiosplug/ COMMENT= Nagios plugins diff --git a/net/nagios-plugins/distinfo b/net/nagios-plugins/distinfo index 37b03624a5e..961155b720b 100644 --- a/net/nagios-plugins/distinfo +++ b/net/nagios-plugins/distinfo @@ -1,8 +1,9 @@ -$NetBSD: distinfo,v 1.6 2008/05/27 21:22:03 tonnerre Exp $ +$NetBSD: distinfo,v 1.7 2008/06/08 14:08:47 tonnerre Exp $ SHA1 (nagios-plugins-1.4.11.tar.gz) = bc91a57ad6f5468b17f24429ba25225cfff45d59 RMD160 (nagios-plugins-1.4.11.tar.gz) = 4f33e796f8eac2d8d13cbecbcc1191857e1b5f15 Size (nagios-plugins-1.4.11.tar.gz) = 1734230 bytes +SHA1 (patch-aa) = 9097c99ecb20b1e12099a9bae77b6d38ed76c331 SHA1 (patch-ab) = aaa6938dd165cf348e798e02c34ee82a86eedf7c SHA1 (patch-ad) = edf12abc20e8dfe4095e4515c27046579639d1ae SHA1 (patch-ae) = 775fc9d8c25eec6050d709e8a377c8deb17bcf66 diff --git a/net/nagios-plugins/patches/patch-aa b/net/nagios-plugins/patches/patch-aa new file mode 100644 index 00000000000..7407e1a7a0f --- /dev/null +++ b/net/nagios-plugins/patches/patch-aa @@ -0,0 +1,26 @@ +$NetBSD: patch-aa,v 1.3 2008/06/08 14:08:47 tonnerre Exp $ + +--- lib/utils_base.c.orig 2007-07-29 14:42:05.000000000 +0200 ++++ lib/utils_base.c +@@ -89,7 +89,7 @@ _set_thresholds(thresholds **my_threshol + { + thresholds *temp_thresholds = NULL; + +- temp_thresholds = malloc(sizeof(temp_thresholds)); ++ temp_thresholds = malloc(sizeof(*temp_thresholds)); + + temp_thresholds->warning = NULL; + temp_thresholds->critical = NULL; +@@ -105,10 +105,9 @@ _set_thresholds(thresholds **my_threshol + } + } + +- if (*my_thresholds > 0) { /* Not sure why, but sometimes could be -1 */ +- /* printf("Freeing here: %d\n", *my_thresholds); */ ++ if (*my_thresholds) + free(*my_thresholds); +- } ++ + *my_thresholds = temp_thresholds; + + return 0; |