From: Dave Seddon <dave.seddon.ca@gmail.com>
To: Frank Dressler <frank@dressler.pro>
Cc: netdev@vger.kernel.org,
Stephen Hemminger <stephen@networkplumber.org>,
David Ahern <dsahern@kernel.org>,
Paolo Lungaroni <paolo.lungaroni@uniroma2.it>
Subject: Re: [PATCH iproute2] seg6local: fix crash when next-csid ends the command
Date: Tue, 24 Nov 2026 07:57:24 -0800 [thread overview]
Message-ID: <20261124155724.2327086-1-dave.seddon.ca@gmail.com> (raw)
In-Reply-To: <a5b77684-1041-49ed-8fd6-567e68964476@dressler.pro>
On Tue, 24 Nov 2026 07:56:52 +0000, Frank Dressler wrote:
> Good find, and your change fixes the segfault.
>
> But I think the way you fix it is a bit uncommon in the code base that
> seems to instead prefer a pattern like
>
> while (NEXT_ARG_OK()) {
[...]
> With that style, you would also fix another bug which is that it
> currently expects lblen and nflen in that specific order which
> contradicts the man page that allows them in any order.
Thanks for the review, Frank.
You're right about the ordering: "flavors next-csid nflen 16 lblen 32"
fails with '"lblen" is garbage', and the man page allows either order.
I'd like to keep this patch as the minimal crash fix, and send the loop
conversion as a separate patch on top, since it changes what the parser
accepts. I'll post that as a follow-up. If people would prefer a single
patch, I'm happy to send a v2 instead.
Thanks,
Dave
prev parent reply other threads:[~2026-11-24 15:57 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-24 5:55 [PATCH iproute2] seg6local: fix crash when next-csid ends the command Dave Seddon
2026-11-24 7:56 ` Frank Dressler
[not found] ` <a5b77684-1041-49ed-8fd6-567e68964476@dressler.pro>
2026-11-24 15:57 ` Dave Seddon [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=20261124155724.2327086-1-dave.seddon.ca@gmail.com \
--to=dave.seddon.ca@gmail.com \
--cc=dsahern@kernel.org \
--cc=frank@dressler.pro \
--cc=netdev@vger.kernel.org \
--cc=paolo.lungaroni@uniroma2.it \
--cc=stephen@networkplumber.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