mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Sasha Levin <sashal@kernel.org>
To: Hamdy Abou El Anein <info@daylightlinux.ch>
Cc: Hamdy Abou El Anein <hamdy.aea@protonmail.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	"Matthieu Baerts (NGI0)" <matttbe@kernel.org>,
	linux-kernel@vger.kernel.org, Sasha Levin <sashal@kernel.org>
Subject: Re: [PATCH] scripts: decode_stacktrace: preserve input while reading lines
Date: Tue,  3 Nov 2026 12:26:28 -0500	[thread overview]
Message-ID: <20261103172629.1393309-3-sashal@kernel.org> (raw)
In-Reply-To: <20261103164203.129660-1-info@daylightlinux.ch>

On Tue, Nov 03, 2026 at 05:42:03PM +0100, Hamdy Abou El Anein wrote:
>Plain read strips leading and trailing whitespace and interprets
>backslashes before the decoder sees a line. It also drops a final line
>without a newline. This loses log text and defeats the alignment
>preservation in handle_line().
>
>Read with an empty IFS and -r, and process a nonempty final fragment.

One optional follow-up: debuginfod_get_vmlinux() takes the build ID with ${1##*
}, so trailing whitespace after the build ID now gives an empty ID and the
lookup fails. The kernel never prints that, since the build ID always ends the
line, so it only matters for logs edited after the fact.

Acked-by: Sasha Levin <sashal@kernel.org>

-- 
Thanks,
Sasha

      reply	other threads:[~2026-11-03 17:26 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-03 16:42 Hamdy Abou El Anein
2026-11-03 17:26 ` Sasha Levin [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=20261103172629.1393309-3-sashal@kernel.org \
    --to=sashal@kernel.org \
    --cc=akpm@linux-foundation.org \
    --cc=hamdy.aea@protonmail.com \
    --cc=info@daylightlinux.ch \
    --cc=linux-kernel@vger.kernel.org \
    --cc=matttbe@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®