Browse Source

execve should set errno

K. Lange 1 year ago
parent
commit
cdcc0edb0b
1 changed files with 1 additions and 1 deletions
  1. 1 1
      libc/unistd/execvp.c

+ 1 - 1
libc/unistd/execvp.c

@@ -9,7 +9,7 @@ extern char * getenv(char *);
 #define DEFAULT_PATH "/bin:/usr/bin"
 
 int execve(const char *name, char * const argv[], char * const envp[]) {
-	return syscall_execve((char*)name,(char**)argv,(char**)envp);
+	__sets_errno(syscall_execve((char*)name,(char**)argv,(char**)envp));
 }
 
 int execvp(const char *file, char *const argv[]) {