Fix potential null dereference
This commit is contained in:
3
etc.c
3
etc.c
@@ -1596,7 +1596,8 @@ file_to_url(char *file)
|
|||||||
char *host = NULL;
|
char *host = NULL;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
file = expandPath(file);
|
if (!(file = expandPath(file)))
|
||||||
|
return NULL;
|
||||||
#ifdef SUPPORT_NETBIOS_SHARE
|
#ifdef SUPPORT_NETBIOS_SHARE
|
||||||
if (file[0] == '/' && file[1] == '/') {
|
if (file[0] == '/' && file[1] == '/') {
|
||||||
char *p;
|
char *p;
|
||||||
|
|||||||
Reference in New Issue
Block a user