Date: Thu, 5 Nov 2020 04:19:48 +0000 (UTC) From: Kyle Evans <kevans@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r367361 - head/sys/kern Message-ID: <202011050419.0A54JmFW037169@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: kevans Date: Thu Nov 5 04:19:48 2020 New Revision: 367361 URL: https://svnweb.freebsd.org/changeset/base/367361 Log: imgact_binmisc: fix up some minor nits - Removed a bunch of redundant headers - Don't explicitly initialize to 0 - The !error check prior to setting imgp->interpreter_name is redundant, all error paths should and do return or go to 'done'. We have larger problems otherwise. Modified: head/sys/kern/imgact_binmisc.c Modified: head/sys/kern/imgact_binmisc.c ============================================================================== --- head/sys/kern/imgact_binmisc.c Thu Nov 5 03:25:23 2020 (r367360) +++ head/sys/kern/imgact_binmisc.c Thu Nov 5 04:19:48 2020 (r367361) @@ -29,17 +29,14 @@ __FBSDID("$FreeBSD$"); #include <sys/param.h> #include <sys/ctype.h> -#include <sys/sbuf.h> -#include <sys/systm.h> -#include <sys/sysproto.h> #include <sys/exec.h> #include <sys/imgact.h> #include <sys/imgact_binmisc.h> #include <sys/kernel.h> -#include <sys/libkern.h> #include <sys/lock.h> #include <sys/malloc.h> #include <sys/mutex.h> +#include <sys/sbuf.h> #include <sys/sysctl.h> #include <sys/sx.h> @@ -97,7 +94,7 @@ MALLOC_DEFINE(M_BINMISC, KMOD_NAME, "misc binary image static SLIST_HEAD(, imgact_binmisc_entry) interpreter_list = SLIST_HEAD_INITIALIZER(interpreter_list); -static int interp_list_entry_count = 0; +static int interp_list_entry_count; static struct sx interp_list_sx; @@ -703,8 +700,7 @@ imgact_binmisc_exec(struct image_params *imgp) *d = '\0'; sx_sunlock(&interp_list_sx); - if (!error) - imgp->interpreter_name = imgp->args->begin_argv; + imgp->interpreter_name = imgp->args->begin_argv; done: if (sname)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202011050419.0A54JmFW037169>