author | Dmitry Marakasov <amdmi3@amdmi3.ru> |
Wed, 25 Dec 2013 23:23:48 +0400 | |
changeset 9799 | a3fe81c3bc02 |
parent 9797 | 1fdc1507e42d |
child 9801 | 8fb7737fbd31 |
--- a/misc/libphysfs/platform_unix.c Sun Dec 15 14:05:42 2013 -0500 +++ b/misc/libphysfs/platform_unix.c Wed Dec 25 23:23:48 2013 +0400 @@ -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 */