Add null/empty parameter guard to FS_CreatePath
This commit is contained in:
parent
6b4b1dc84d
commit
693c1f1e92
|
|
@ -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, "::" ) ) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user