Bug 689195: Fix signed/unsigned comparison warning in nsLocalFileUnix.cpp. r=smichaud
authorDaniel Holbert <dholbert@cs.stanford.edu>
Mon, 26 Sep 2011 15:00:34 -0700
changeset 77615 95a1d14917c4638f3c3d634b9d94000f3848571b
parent 77614 9b6d23e07968bbdf63224d9e25e535b6cd856067
child 77616 cadb12b21740b04b662752d6c0b703713d387129
push id2170
push userdholbert@mozilla.com
push dateMon, 26 Sep 2011 22:01:18 +0000
treeherdermozilla-inbound@95a1d14917c4 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerssmichaud
bugs689195
milestone9.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 689195: Fix signed/unsigned comparison warning in nsLocalFileUnix.cpp. r=smichaud
xpcom/io/nsLocalFileUnix.cpp
--- a/xpcom/io/nsLocalFileUnix.cpp
+++ b/xpcom/io/nsLocalFileUnix.cpp
@@ -1424,17 +1424,17 @@ nsLocalFile::IsExecutable(PRBool *_retva
         for(p += dotIdx + 1; *p; p++)
             *p +=  (*p >= L'A' && *p <= L'Z') ? 'a' - 'A' : 0; 
         
         // Search for any of the set of executable extensions.
         static const char * const executableExts[] = {
             "air",         // Adobe AIR installer
             "jar"};        // java application bundle
         nsDependentSubstring ext = Substring(path, dotIdx + 1);
-        for (int i = 0; i < NS_ARRAY_LENGTH(executableExts); i++) {
+        for (size_t i = 0; i < NS_ARRAY_LENGTH(executableExts); i++) {
             if (ext.EqualsASCII(executableExts[i])) {
                 // Found a match.  Set result and quit.
                 *_retval = PR_TRUE;
                 return NS_OK;
             }
         }
     }