Bill Blough created XERCESC-2085:
------------------------------------
Summary: Crash in PSVIWriter due to strrchr returning NULL
Key: XERCESC-2085
URL: https://issues.apache.org/jira/browse/XERCESC-2085
Project: Xerces-C++
Issue Type: Bug
Components: Samples/Tests
Environment: Debian GNU/Linux amd64
Reporter: Bill Blough
Priority: Minor
This was reported in Debian quite some time ago (I was not maintainer then). I
have fixed it in Debian and am forwarding my patch.
The original Debian bug report can be found at
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=715592
PSVIWriter uses strrchr but does not properly handle a NULL return value,
causing strcat to attempt to dereference a NULL pointer.
My patch adds a check that the result of strrchr (for the '/' case) is not null
before executing the strcat. The case for '\\' is not affected because of the
"greater than" check just prior.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]