Subject: Re: pkg/30948
To: None <rillig@netbsd.org, gnats-admin@netbsd.org,>
From: Roland Illig <rillig@NetBSD.org>
List: pkgsrc-bugs
Date: 12/05/2005 08:30:05
The following reply was made to PR pkg/30948; it has been noted by GNATS.

From: Roland Illig <rillig@NetBSD.org>
To: huajian.luo@sun.com
Cc: gnats-bugs@netbsd.org
Subject: Re: pkg/30948
Date: Mon, 05 Dec 2005 09:29:55 +0100

 This is a multi-part message in MIME format.
 --------------070809020302030607060102
 Content-Type: text/plain; charset=us-ascii; format=flowed
 Content-Transfer-Encoding: 7bit
 
 Thanks for the information. I suppose there is some NullPointerException 
 in the config_node_remove function. Can you please try the appended patch?
 
 And please have a look at your ~/.irssi/config file to see if there is 
 anything in it that might confuse the config file parser. If it looks 
 "normal", you should file a bug report against irssi itself, not against 
 pkgsrc.
 
 Roland
 
 --------------070809020302030607060102
 Content-Type: text/plain;
  name="chat-irssi.patch"
 Content-Transfer-Encoding: 7bit
 Content-Disposition: inline;
  filename="chat-irssi.patch"
 
 Index: distinfo
 ===================================================================
 RCS file: /cvsroot/pkgsrc/chat/irssi/distinfo,v
 retrieving revision 1.22
 diff -p -u -r1.22 distinfo
 --- distinfo	11 Nov 2005 16:01:20 -0000	1.22
 +++ distinfo	5 Dec 2005 08:22:56 -0000
 @@ -9,3 +9,4 @@ SHA1 (patch-ac) = 9572891333279dc368f44c
  SHA1 (patch-ad) = 7629117264f84c4f20697200456f91662b52f724
  SHA1 (patch-ae) = 158de7394abec0cab8fe2c8fea158fd97377cb1f
  SHA1 (patch-af) = 3603d84e9e3b5f589c94775e261dedcacff09cf0
 +SHA1 (patch-ba) = cfb4f611d5ac1aeda0e5591558bb4cab4f4e6eb4
 --- /dev/null	2005-12-05 09:15:56.000000000 +0100
 +++ patches/patch-ba	2005-12-05 09:15:55.470792000 +0100
 @@ -0,0 +1,20 @@
 +$NetBSD$
 +
 +--- src/lib-config/set.c.orig	2002-02-15 23:18:35.000000000 +0100
 ++++ src/lib-config/set.c	2005-12-05 09:15:46.784951000 +0100
 +@@ -47,6 +47,7 @@ void config_node_remove(CONFIG_REC *rec,
 + 	case NODE_TYPE_KEY:
 + 	case NODE_TYPE_VALUE:
 + 	case NODE_TYPE_COMMENT:
 ++		g_return_if_fail(node->value != NULL);
 + 		g_free_not_null(node->value);
 + 		break;
 + 	case NODE_TYPE_BLOCK:
 +@@ -55,6 +56,7 @@ void config_node_remove(CONFIG_REC *rec,
 + 			config_node_remove(rec, node, ((GSList *) node->value)->data);
 + 		break;
 + 	}
 ++	g_return_if_fail(node->key != NULL);
 + 	g_free_not_null(node->key);
 +         g_free(node);
 + }
 
 --------------070809020302030607060102--