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] [day] [month] [year] [list]
Message-ID: <2024090629-exploit-striving-d2c3@gregkh>
Date: Fri, 6 Sep 2024 13:59:25 +0200
From: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
To: Ruffalo Lavoisier <ruffalolavoisier@...il.com>
Cc: Ian Abbott <abbotti@....co.uk>,
	H Hartley Sweeten <hsweeten@...ionengravers.com>,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] ni_routing: Check when the file could not be opened

On Fri, Sep 06, 2024 at 08:54:02PM +0900, Ruffalo Lavoisier wrote:
> Signed-off-by: Ruffalo Lavoisier <RuffaloLavoisier@...il.com>

For obvious reasons, we can't take patches without a changelog :(

> ---
>  drivers/comedi/drivers/ni_routing/tools/convert_c_to_py.c | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/drivers/comedi/drivers/ni_routing/tools/convert_c_to_py.c b/drivers/comedi/drivers/ni_routing/tools/convert_c_to_py.c
> index d55521b5bdcb..d0321a7565c5 100644
> --- a/drivers/comedi/drivers/ni_routing/tools/convert_c_to_py.c
> +++ b/drivers/comedi/drivers/ni_routing/tools/convert_c_to_py.c
> @@ -139,6 +139,10 @@ void device_write(const struct ni_device_routes *dR, FILE *fp)
>  int main(void)
>  {
>  	FILE *fp = fopen("ni_values.py", "w");
> +	if (fp == NULL) {
> +		fprintf(stderr, "Could not open file!");
> +		return -1;
> +	}

Did you run this through checkpatch.pl?  I think you need a blank line
before your check.

And is this fixing a real-world issue, or just something you noticed?

thanks,

greg k-h

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ