BUG #4912: server core dumps on xslt_process with empty param string - Mailing list pgsql-bugs

From Tom Bowden
Subject BUG #4912: server core dumps on xslt_process with empty param string
Date
Msg-id 200907092105.n69L5dnf000795@wwwmaster.postgresql.org
Whole thread Raw
Responses Re: BUG #4912: server core dumps on xslt_process with empty param string
List pgsql-bugs
The following bug has been logged online:

Bug reference:      4912
Logged by:          Tom Bowden
Email address:      tom.bowden@fis-cal.com
PostgreSQL version: 8.4rc2
Operating system:   Linux 2.6.22.5-31-bigsmp
Description:        server core dumps on xslt_process with empty param
string
Details:

I found that when using xslt_process(), either with two parameters, or with
an empty/null third parameter -- that I get a 'server restarted' message.

To stop this behavior, I changed the source code in contrib/xml2/xslt_proc.c
(around line 142) .. adding the following:
if ( pstr == NULL ||  strlen(pstr) < 1 ) {
          params[0] = NULL;
          return;
}


I don't know if this is the right place to report this; whether there is a
better way (or not) to fix it,(add any other disclaimers you might want to
add - or tell me where you want me to go with this :).


Tom

pgsql-bugs by date:

Previous
From: "Brian Ceccarelli"
Date:
Subject: BUG #4911: Cannot assign a value to a member of a nested composite type.
Next
From: "Mathieu De Zutter"
Date:
Subject: BUG #4913: Row missing from primary key index