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: <20240515160040.GL2118490@ZenIV>
Date: Wed, 15 May 2024 17:00:40 +0100
From: Al Viro <viro@...iv.linux.org.uk>
To: Jiasheng Jiang <jiashengjiangcool@...look.com>
Cc: brauner@...nel.org, jack@...e.cz, arnd@...db.de, gregkh@...e.de,
	linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] libfs: fix implicitly cast in simple_attr_write_xsigned()

On Wed, May 15, 2024 at 03:17:25PM +0000, Jiasheng Jiang wrote:
> Return 0 to indicate failure and return "len" to indicate success.
> It was hard to distinguish success or failure if "len" equals the error
> code after the implicit cast.
> Moreover, eliminating implicit cast is a better practice.

According to whom?

Merits of your ex cathedra claims aside, you do realize that functions
have calling conventions because they are, well, called, right?
And changing the value returned in such and such case should be
accompanied with the corresponding change in the _callers_.

Al, wondering if somebody had decided to play with LLM...

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ