All of lore.kernel.org
 help / color / mirror / Atom feed
From: Simon Horman <horms@kernel.org>
To: "Maximilian Güntner" <code@mguentner.de>
Cc: netdev@vger.kernel.org, David Ahern <dsahern@kernel.org>,
	"David S. Miller" <davem@davemloft.net>
Subject: Re: [PATCH] ipv4: output metric as unsigned int
Date: Fri, 13 Dec 2024 12:18:55 +0000	[thread overview]
Message-ID: <20241213121855.GU2110@kernel.org> (raw)
In-Reply-To: <20241212161911.51598-1-code@mguentner.de>

On Thu, Dec 12, 2024 at 05:19:11PM +0100, Maximilian Güntner wrote:
> adding a route metric greater than 0x7fff_ffff leads to an
> unintended wrap when printing the underlying u32 as an
> unsigned int (`%d`) thus incorrectly rendering the metric
> as negative.  Formatting using `%u` corrects the issue.
> 
> Signed-off-by: Maximilian Güntner <code@mguentner.de>

Reviewed-by: Simon Horman <horms@kernel.org>


  reply	other threads:[~2024-12-13 12:18 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-12 16:19 [PATCH] ipv4: output metric as unsigned int Maximilian Güntner
2024-12-13 12:18 ` Simon Horman [this message]
2024-12-15 21:30 ` patchwork-bot+netdevbpf

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=20241213121855.GU2110@kernel.org \
    --to=horms@kernel.org \
    --cc=code@mguentner.de \
    --cc=davem@davemloft.net \
    --cc=dsahern@kernel.org \
    --cc=netdev@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.