From: David Miller <davem@davemloft.net>
To: Benjamin.Thery@bull.net
Cc: shemminger@vyatta.com, netdev@vger.kernel.org
Subject: Re: [PATCH] net: fix /proc/net/ip_mr_cache display
Date: Tue, 02 Dec 2008 15:03:30 -0800 (PST) [thread overview]
Message-ID: <20081202.150330.157587697.davem@davemloft.net> (raw)
In-Reply-To: <20081201211702.a8cjo5p08wscwcwg@intran0x.frec.bull.fr>
From: "Benjamin Thery " <Benjamin.Thery@bull.net>
Date: Mon, 01 Dec 2008 21:17:02 +0100
> The right way to fix it, IMHO, is to print 0 (zero) in the columns
> that have no meaning for the unresolved entries. That way we don't
> break the ABI: the userspace expects to get at least 6 numbers for
> each entries, it gets 6 numbers. It's easy to figure what zeros
> represent and this prevent people from wasting time trying to figure
> what to do with these "random" numbers on the unresolved entries, no?
Probably, this is correct.
However, we could run into problems if userland parsers expect
6 entries and then expect an immediate newline. We'd break that.
The only thing that really works for extending files like this
is if they are already exporting a "key: value" interface, then
you can add new lines safely.
Doing this horizontal expansion as you are proposing here is,
on the other hand, very risky and dangerous.
I really don't think it's worth it.
Fix the garbage values, or flush them to zero if we can't
represent them properly. But don't add new stuff horizontally
to "fill in the gaps", as I don't think it can be done %100
safely.
next prev parent reply other threads:[~2008-12-02 23:03 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-12-01 16:02 [PATCH] net: fix /proc/net/ip_mr_cache display Benjamin Thery
2008-12-01 16:49 ` Benjamin Thery
2008-12-01 17:33 ` Stephen Hemminger
2008-12-01 20:17 ` Benjamin Thery
2008-12-02 23:03 ` David Miller [this message]
2008-12-03 13:48 ` Benjamin Thery
2008-12-03 14:35 ` [PATCH 1/2] net: fix /proc/net/ip_mr_cache display - V2 Benjamin Thery
2008-12-04 6:21 ` David Miller
2008-12-03 14:35 ` [PATCH 2/2] net: /proc/net/ip_mr_cache, display Iif as a signed short Benjamin Thery
2008-12-04 6:22 ` David Miller
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=20081202.150330.157587697.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=Benjamin.Thery@bull.net \
--cc=netdev@vger.kernel.org \
--cc=shemminger@vyatta.com \
/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;
as well as URLs for NNTP newsgroup(s).