diff --git a/mozilla/base/src/unix/nsFileSpecUnix.cpp b/mozilla/base/src/unix/nsFileSpecUnix.cpp index 8b783a24d77..f6c2cf7b070 100644 --- a/mozilla/base/src/unix/nsFileSpecUnix.cpp +++ b/mozilla/base/src/unix/nsFileSpecUnix.cpp @@ -94,7 +94,7 @@ void nsFileSpecHelpers::Canonify(nsSimpleCharString& ioPath, PRBool inMakeDirs) strcat(buffer, ++lastSeparator); } } - if (!canonicalPath && *ioPath != '/' && !inMakeDirs) + if (!canonicalPath && ioPath[0] != '/' && !inMakeDirs) { // Well, if it's a relative path, hack it ourselves. canonicalPath = realpath(".", buffer); diff --git a/mozilla/xpcom/io/nsFileSpecUnix.cpp b/mozilla/xpcom/io/nsFileSpecUnix.cpp index 8b783a24d77..f6c2cf7b070 100644 --- a/mozilla/xpcom/io/nsFileSpecUnix.cpp +++ b/mozilla/xpcom/io/nsFileSpecUnix.cpp @@ -94,7 +94,7 @@ void nsFileSpecHelpers::Canonify(nsSimpleCharString& ioPath, PRBool inMakeDirs) strcat(buffer, ++lastSeparator); } } - if (!canonicalPath && *ioPath != '/' && !inMakeDirs) + if (!canonicalPath && ioPath[0] != '/' && !inMakeDirs) { // Well, if it's a relative path, hack it ourselves. canonicalPath = realpath(".", buffer);