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 77624 95a1d14917c4638f3c3d634b9d94000f3848571b
parent 77623 9b6d23e07968bbdf63224d9e25e535b6cd856067
child 77625 cadb12b21740b04b662752d6c0b703713d387129
push id3
push userfelipc@gmail.com
push dateFri, 30 Sep 2011 20:09:13 +0000
reviewerssmichaud
bugs689195
milestone9.0a1
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;
             }
         }
     }