[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1497851952.8495.42.camel@perches.com>
Date: Sun, 18 Jun 2017 22:59:12 -0700
From: Joe Perches <joe@...ches.com>
To: Govindarajulu Varadarajan <gvaradar@...co.com>
Cc: davem@...emloft.net, netdev@...r.kernel.org, benve@...co.com
Subject: Re: [PATCH net-next] enic: use kasprintf instead of snprintf
On Sun, 2017-06-18 at 22:55 -0700, Govindarajulu Varadarajan wrote:
> On Sun, 18 Jun 2017, Joe Perches wrote:
>
> > Perhaps it'd be better to use a style
> > with a variable length format precision
> >
> > ie:
> >
> > "%.*s-tx-%u", IFNAMSIZ - 4 - <something>, netdev-name, i)
> >
>
> This would truncate interface name. Why is this preferred to my patch?
no allocation required, simpler.
Powered by blists - more mailing lists