Fix Strcmp - it didn't have consistent null pointer handling - revert to what it used to be - a lightweight wrapper around strcmp which means functions once again must not pass in null to it.

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13943 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
William S Fulton 2012-12-02 13:36:13 +00:00
commit 89052f3b0a
8 changed files with 18 additions and 17 deletions

View file

@ -1577,7 +1577,8 @@ public:
while (i.item) {
Node *j = firstChild(i.item);
while (j) {
if (Strcmp(Getattr(j, "name"), Getattr(n, "name")) != 0) {
String *jname = Getattr(j, "name");
if (!jname || Strcmp(jname, Getattr(n, "name")) != 0) {
j = nextSibling(j);
continue;
}