Add null/empty parameter guard to FS_CreatePath
This commit is contained in:
1 parent
6b4b1dc84d
commit
693c1f1e92
1 file changed
+4
@@ -547,6 +547,10 @@ qboolean FS_CreatePath (const char *OSPath) {
|
||||
char *ofs;
|
||||
char path[MAX_OSPATH];
|
||||
|
||||
if (!OSPath || !*OSPath) {
|
||||
return qfalse;
|
||||
}
|
||||
|
||||
// make absolutely sure that it can't back up the path
|
||||
// FIXME: is c: allowed???
|
||||
if ( strstr( OSPath, ".." ) || strstr( OSPath, "::" ) ) {
|
||||
|
||||
Reference in new issue
Block a user