]> de.git.xonotic.org Git - xonotic/netradiant.git/blobdiff - tools/quake3/common/cmdlib.c
fix some more warnings
[xonotic/netradiant.git] / tools / quake3 / common / cmdlib.c
index fac9bdbbd546d9d673f280d952802f48178423d3..5168d233f38846dc7014351cc8200f83ab496af1 100644 (file)
@@ -336,7 +336,7 @@ void Q_getwd (char *out)
    strcat (out, "\\");
 #else
    // Gef: Changed from getwd() to getcwd() to avoid potential buffer overflow
-   getcwd (out, 256);
+   if(!getcwd (out, 256)) *out = 0;
    strcat (out, "/");
 #endif
    while ( out[i] != 0 )