Re: [PATCH 3/6] lib80211: re-use string_escape_mem_any_np()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, 2014-07-02 at 06:43 -0700, Joe Perches wrote:
> On Wed, 2014-07-02 at 16:20 +0300, Andy Shevchenko wrote:
> > In kernel we have function to escape a given string. Let's use it instead of
> > custom approach.
> > 
> > This fixes a bug. The current implementation wrongly prints octal numbers: only
> > two first digits are used in case when 3 are required and the rest of the
> > string ends up cut off.

[]

> This code looks like it was adapted from the old print_mac
> ethernet code that was eventually replaced by a vsprintf
> pointer extension %pM
> 
> So a better way to do this might be to add and use yet
> another vsprintf %p<foo> extension for ssids.

Might be, but it
 - doesn't reduce necessity of string_escape_mem (not only ssid are
escaped in kernel)
 - prevents user to choose a rule what exactly their would like to
escape (look at the other patches against ssid escaping)

-- 
Andy Shevchenko <andriy.shevchenko@xxxxxxxxx>
Intel Finland Oy

_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel




[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux