From: Willy Tarreau <w@1wt.eu>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: David Miller <davem@davemloft.net>,
Eric Dumazet <eric.dumazet@gmail.com>,
Network Development List <netdev@vger.kernel.org>
Subject: Re: [PATCH] nf_conntrack: avoid kernel pointer value leak in slab name
Date: Sun, 15 May 2016 07:22:40 +0200 [thread overview]
Message-ID: <20160515052240.GA10828@1wt.eu> (raw)
In-Reply-To: <CA+55aFwthSgQyG_=mTpwctpOWqc1D7KgWHrdrqh+PLiFjuT=_A@mail.gmail.com>
On Sat, May 14, 2016 at 03:21:31PM -0700, Linus Torvalds wrote:
> On Sat, May 14, 2016 at 2:33 PM, Willy Tarreau <w@1wt.eu> wrote:
> >
> > Why simply not cast the atomic to (unsigned long long) instead of (u64)
> > so that %llu always matches ?
>
> Yes, that fixes the problem. It's just more typing, and annoying. The
> fact that MS got it right while posix and gcc screwed it up is a bit
> embarrassing..
Well on the other hand, because of this MS still has problems porting
code from 32 to 64 bit. The real problem is that on both sides they
imagined that you needed only one way to specify your types. In practice
users generally want either the most optimal types for the architecture
because they don't care about the size (char, int, size_t, void *...)
or a specific size. This last one is annoying to use with printf format.
> If we ever start using __uint128_t, we'll have even more problems in
> this area. Oh well.
Definitely.
Willy
next prev parent reply other threads:[~2016-05-15 5:22 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-05-14 18:24 [PATCH] nf_conntrack: avoid kernel pointer value leak in slab name Linus Torvalds
2016-05-14 18:46 ` Eric Dumazet
2016-05-14 19:16 ` David Miller
2016-05-14 21:31 ` Linus Torvalds
2016-05-14 21:33 ` Willy Tarreau
2016-05-14 22:21 ` Linus Torvalds
2016-05-15 5:22 ` Willy Tarreau [this message]
2016-05-15 18:05 ` Linus Torvalds
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=20160515052240.GA10828@1wt.eu \
--to=w@1wt.eu \
--cc=davem@davemloft.net \
--cc=eric.dumazet@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=torvalds@linux-foundation.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.