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: <20251230123336.ef33f8a55df71f3e3f782532@linux-foundation.org>
Date: Tue, 30 Dec 2025 12:33:36 -0800
From: Andrew Morton <akpm@...ux-foundation.org>
To: Michal Hocko <mhocko@...e.com>
Cc: Dipendra Khadka <kdipendra88@...il.com>, David Rientjes
 <rientjes@...gle.com>, Shakeel Butt <shakeel.butt@...ux.dev>,
 linux-mm@...ck.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] mm/oom_kill: Remove unnecessary integer promotion in
 format string

On Mon, 29 Dec 2025 09:27:18 +0100 Michal Hocko <mhocko@...e.com> wrote:

> On Sun 28-12-25 15:44:55, Dipendra Khadka wrote:
> > The 'h' length modifier in '%hd' is unnecessary as short integers are
> > promoted to int in variadic functions. Use '%d' instead.
> > 
> > Signed-off-by: Dipendra Khadka <kdipendra88@...il.com>
> 
> Why should we change the currently correct code in the first place?
> What is an added value?

It reduces vmlinux by 2 bytes ;)

It's a teeny issue but I do like the present code - be very explicit
and careful about the types we're dealing with, don't rely on unobvious
C rules.


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ