lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Sat, 03 Sep 2016 14:42:57 +0200
From:   walter harms <wharms@....de>
To:     SF Markus Elfring <elfring@...rs.sourceforge.net>
CC:     linux-s390@...r.kernel.org,
        David Hildenbrand <dahi@...ux.vnet.ibm.com>,
        Heiko Carstens <heiko.carstens@...ibm.com>,
        Joe Perches <joe@...ches.com>,
        Martin Schwidefsky <schwidefsky@...ibm.com>,
        LKML <linux-kernel@...r.kernel.org>,
        kernel-janitors@...r.kernel.org,
        Julia Lawall <julia.lawall@...6.fr>,
        Paolo Bonzini <pbonzini@...hat.com>
Subject: Re: [PATCH 09/17] s390/debug: Return directly if a null pointer was
 passed to debug_unregister()



Am 03.09.2016 14:24, schrieb SF Markus Elfring:
> From: Markus Elfring <elfring@...rs.sourceforge.net>
> Date: Thu, 1 Sep 2016 19:34:45 +0200
> 
> Return directly at the beginning if a null pointer was passed for
> the input parameter of this function.
> 
> Signed-off-by: Markus Elfring <elfring@...rs.sourceforge.net>
> ---
>  arch/s390/kernel/debug.c | 5 +----
>  1 file changed, 1 insertion(+), 4 deletions(-)
> 
> diff --git a/arch/s390/kernel/debug.c b/arch/s390/kernel/debug.c
> index c4a4641..d137150 100644
> --- a/arch/s390/kernel/debug.c
> +++ b/arch/s390/kernel/debug.c
> @@ -736,13 +736,10 @@ void
>  debug_unregister(debug_info_t * id)
>  {
>  	if (!id)
> -		goto out;
> +		return;
>  	mutex_lock(&debug_mutex);
>  	debug_info_put(id);
>  	mutex_unlock(&debug_mutex);
> -
> -out:
> -	return;
>  }
>  EXPORT_SYMBOL(debug_unregister);
> 

debug_info_put() will check for NULL, the whole check can be removed.

re,
 wh

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ