mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-03 02:15:43 -04:00
Oops, small mistake
This commit is contained in:
parent
3e3301dfb8
commit
2b6617793c
@ -170,8 +170,10 @@ int main(int argc, char **argv)
|
|||||||
|
|
||||||
// Ask linux for the file name of this executable.
|
// Ask linux for the file name of this executable.
|
||||||
int ok = readlink("/proc/self/exe", fnbuf, PATH_MAX-1);
|
int ok = readlink("/proc/self/exe", fnbuf, PATH_MAX-1);
|
||||||
if (ok<0 && argc > 0) strcpy(fnbuf, argv[0]);
|
if (ok<0) {
|
||||||
|
if (argc>0) strcpy(fnbuf, argv[0]);
|
||||||
else errorexit("Cannot read /proc/sys/exe");
|
else errorexit("Cannot read /proc/sys/exe");
|
||||||
|
}
|
||||||
fnbuf[PATH_MAX-1] = 0;
|
fnbuf[PATH_MAX-1] = 0;
|
||||||
fnlen = strlen(fnbuf);
|
fnlen = strlen(fnbuf);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user