summaryrefslogtreecommitdiff
path: root/src/java-utils.c
diff options
context:
space:
mode:
authorrbuj <[email protected]>2019-08-30 01:06:03 +0200
committerZenWalker <[email protected]>2019-09-01 13:12:02 +0200
commit07a226bcdd0b2b887fbd757ca910c56dea470095 (patch)
treeadbb17b7df6d75488188cf3a545dccf1a8c3c7e4 /src/java-utils.c
parent9f10fa5b87f469b7b6bcc8146e4997452e09a299 (diff)
downloadengrampa-07a226bcdd0b2b887fbd757ca910c56dea470095.tar.bz2
engrampa-07a226bcdd0b2b887fbd757ca910c56dea470095.tar.xz
comparison of unsigned expression >= 0 is always true
java-utils.c:310:23: warning: comparison of unsigned expression >= 0 is always true [-Wtype-limits] 310 | for (i = length; (i >= 0) && (end == 0); i-- ) | ^~
Diffstat (limited to 'src/java-utils.c')
-rw-r--r--src/java-utils.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/java-utils.c b/src/java-utils.c
index 6946761..5b36a9c 100644
--- a/src/java-utils.c
+++ b/src/java-utils.c
@@ -307,9 +307,10 @@ get_package_name_from_class_file (char *fname)
}
if (package != NULL) {
- for (i = length; (i >= 0) && (end == 0); i-- )
- if (package[i] == '/')
- end = i;
+ int j;
+ for (j = length; (j >= 0) && (end == 0); j--)
+ if (package[j] == '/')
+ end = j;
package = g_strndup (package, end);
}