misc/libphysfs/platform_unix.c
branchsdl2transition
changeset 11342 ed5a6478e710
parent 9799 a3fe81c3bc02
child 12218 bb5522e88ab2
--- a/misc/libphysfs/platform_unix.c	Tue Nov 10 18:16:35 2015 +0100
+++ b/misc/libphysfs/platform_unix.c	Tue Nov 10 20:43:13 2015 +0100
@@ -193,7 +193,7 @@
 
         if (access(exe, X_OK) == 0)  /* Exists as executable? We're done. */
         {
-            exe[size - binlen] = '\0'; /* chop off filename, leave '/' */
+            exe[size - binlen - 1] = '\0'; /* chop off filename, leave '/' */
             return exe;
         } /* if */