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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <81a620bb-205f-45f7-9036-e8e44a8e7be9@gmx.de>
Date: Wed, 5 Mar 2025 18:07:41 +0100
From: Helge Deller <deller@....de>
To: Markus Elfring <Markus.Elfring@....de>,
 Dan Carpenter <dan.carpenter@...aro.org>,
 Uwe Kleine-König <u.kleine-koenig@...libre.com>,
 kernel-janitors@...r.kernel.org, linux-fbdev@...r.kernel.org,
 dri-devel@...ts.freedesktop.org
Cc: Antonino Daplas <adaplas@....net>, Thomas Zimmermann
 <tzimmermann@...e.de>, Yihao Han <hanyihao@...o.com>, cocci@...ia.fr,
 LKML <linux-kernel@...r.kernel.org>
Subject: Re: video: au1100fb: Move a variable assignment behind a null pointer
 check in au1100fb_setmode()

On 3/5/25 13:14, Markus Elfring wrote:
>> Anyway, none of that applies here, because this is just pointer math.
> Which data processing do you expect to be generally supported at the discussed
> source code place (according to the rules of the programming language “C”)?
> https://en.cppreference.com/w/c/language/behavior

There is nothing to discuss.
Dan is correct.

We have:
struct au1100fb_device {
         struct fb_info info;
...

so:

struct fb_info *info = &fbdev->info;
gets translated by the compiler to a trivial pointer math:
info = <value of fbdev> + 0     # 0 is there offset of "info" in the struct.

No crash or anything can or will happen here.

Markus, maybe you missed the "&" in front of "&fbdev->info" ?

Helge

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ