All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dan Carpenter <error27@gmail.com>
To: Arka Mondal <arkamondalofficial@gmail.com>
Cc: smatch@vger.kernel.org
Subject: Re: [PATCH 0/4] fix build warnings on gcc-16 and glibc-2.43
Date: Mon, 17 Aug 2026 11:26:33 +0300	[thread overview]
Message-ID: <aoLFuThVPDfZUtRR@stanley.mountain> (raw)
In-Reply-To: <20260814070954.944614-1-arkamondalofficial@gmail.com>

Thanks,  I applied this to the devel branch of Smatch.

https://github.com/error27/smatch/tree/devel

On Fri, Aug 14, 2026 at 04:09:50PM +0900, Arka Mondal wrote:
> Smatch builds with 14 warnings on gcc-16 and glibc-2.43.  This fixes 12.
> Only the last patch changes behavior: it returns instead of storing a
> truncated name.
> 
> Six of these are new. glibc-2.43 returns const from strchr() and strstr()
> on const strings, and gcc-15 defaults to -std=gnu23 which enables it.
> 
> Two are left.  assume_indexes_are_valid() is unused because its add_hook()
> call is commented out.
> 
> The other is in smatch_kernel_user_data.c:
> 
>       if (param_data_treat_untagged(value) || sym->ctype.as == 5)
> 
> ctype.as is a struct ident pointer, so this is never true.  It has never
> worked: ctype.as became an ident in 69fce9f7 (Dec 2018), this code in 5f2fcd8a (Oct
> 2019).  Revive the check or delete the condition?

I didn't write that code and I did ask about it but I'm not sure what
was intended really...  I've deleted it, since it hopefully can't
possibly be true...  I'll push that later.

(I worry that there is an reason for that weird condition.  Perhaps it
was a hack around for memory corruption or something. :P  But surely all
those ancient bugs have been replaced with new bugs by now).

regards,
dan carpenter


      parent reply	other threads:[~2026-08-17  8:26 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-14  7:09 [PATCH 0/4] fix build warnings on gcc-16 and glibc-2.43 Arka Mondal
2026-08-14  7:09 ` [PATCH 1/4] smatch: use const pointers for strchr() and strstr() results Arka Mondal
2026-08-14  7:09 ` [PATCH 2/4] smatch: delete unused variables Arka Mondal
2026-08-14  7:09 ` [PATCH 3/4] untracked_param: fix a -Wwrite-strings warning Arka Mondal
2026-08-14  7:09 ` [PATCH 4/4] comparison: silence a -Wformat-truncation warning Arka Mondal
2026-08-17  8:26 ` Dan Carpenter [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=aoLFuThVPDfZUtRR@stanley.mountain \
    --to=error27@gmail.com \
    --cc=arkamondalofficial@gmail.com \
    --cc=smatch@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.