From ae432f93f28bc2a60c708a33b77ad08e34501984 Mon Sep 17 00:00:00 2001 From: jhb Date: Mon, 6 Feb 2006 22:06:54 +0000 Subject: - Always call exec_free_args() in kern_execve() instead of doing it in all the callers if the exec either succeeds or fails early. - Move the code to call exit1() if the exec fails after the vmspace is gone to the bottom of kern_execve() to cut down on some code duplication. --- sys/compat/svr4/svr4_misc.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'sys/compat/svr4') diff --git a/sys/compat/svr4/svr4_misc.c b/sys/compat/svr4/svr4_misc.c index 7fae260..5a585cf 100644 --- a/sys/compat/svr4/svr4_misc.c +++ b/sys/compat/svr4/svr4_misc.c @@ -175,7 +175,6 @@ svr4_sys_execv(td, uap) free(path, M_TEMP); if (error == 0) error = kern_execve(td, &eargs, NULL); - exec_free_args(&eargs); return (error); } @@ -195,7 +194,6 @@ svr4_sys_execve(td, uap) free(path, M_TEMP); if (error == 0) error = kern_execve(td, &eargs, NULL); - exec_free_args(&eargs); return (error); } -- cgit v1.1