Avoid NULL dereference

This commit is contained in:
Kevin Lo 2012-09-23 08:38:06 +00:00
parent e06f3469e0
commit 6e427123e2

View File

@ -1256,8 +1256,10 @@ nfs_open(const char *upath, struct open_file *f)
error = 0;
out:
free(newfd);
free(path);
if (newfd)
free(newfd);
if (path)
free(path);
#else
currfd->iodesc = desc;