ports/131993: net-mgmt/nagios: Bus error on nagios 3.0.x with perl 5.8.9
Sebastián Guarino
sebastian.guarino at gmail.com
Tue Feb 24 13:00:12 UTC 2009
The following reply was made to PR ports/131993; it has been noted by GNATS.
From: =?ISO-8859-1?Q?Sebasti=E1n_Guarino?= <sebastian.guarino at gmail.com>
To: bug-followup at FreeBSD.org
Cc: jarrod at netleader.com.au
Subject: Re: ports/131993: net-mgmt/nagios: Bus error on nagios 3.0.x with
perl 5.8.9
Date: Tue, 24 Feb 2009 10:28:21 -0200
This is a multi-part message in MIME format.
--------------070504000804050006040806
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
Here is a patch to the files directory on the nagios ports that makes
nagios work properly.
And here is a link to my post on nagios-devel.
http://article.gmane.org/gmane.network.nagios.devel/6059).
It was a problem of not using a dynamic variable when using embedded perl.
Maybe it can be included first in the port to get 3.0.x work instead of
waiting a new release.
Sebastian Guarino
--------------070504000804050006040806
Content-Type: text/x-csrc;
name="patch-utils.c"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
filename="patch-utils.c"
--- base/utils.c-old 2009-02-23 15:36:28.000000000 -0200
+++ base/utils.c 2009-02-23 16:00:51.000000000 -0200
@@ -3597,7 +3597,7 @@
/* initializes embedded perl interpreter */
int init_embedded_perl(char **env){
#ifdef EMBEDDEDPERL
- char *embedding[]={ "", "" };
+ void **embedding;
int exitstatus=0;
char *temp_buffer=NULL;
int argc=2;
@@ -3612,8 +3612,11 @@
}
else{
-
- embedding[1]=p1_file;
+ embedding = (void **)malloc(2*sizeof(char *));
+ if(embedding==NULL)
+ return ERROR;
+ *embedding=strdup("");
+ *(embedding+1)=strdup(p1_file);
use_embedded_perl=TRUE;
--------------070504000804050006040806--
More information about the freebsd-ports-bugs
mailing list