BarryServer : Git

All the code for all my projects
// BarryServer : Git / Nucleus / commit / d3f787c50eda2dadb77ae216aef1f0bd0a686ae3 / vfs / open.c

// Related

Nucleus

Barry More VFS functions and structure d3f787c (3 years, 2 months ago)
diff --git a/vfs/open.c b/vfs/open.c
index 9dd8978..cac1512 100644
--- a/vfs/open.c
+++ b/vfs/open.c
@@ -116,6 +116,8 @@ end:
 int
 open(const char *name, int flags, ...)
 {
+	if (!name)
+		return -EFAULT;
 	if (!verify_access(name, strnlen(name, PATH_MAX), PROT_READ))
 		return -EFAULT;