lkml.org 
[lkml]   [2014]   [Feb]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH v7 1/3] mm: add kstrdup_trimnl function
    On Tue,  4 Feb 2014 12:43:49 -0800 Sebastian Capella <sebastian.capella@linaro.org> wrote:

    > kstrdup_trimnl creates a duplicate of the passed in
    > null-terminated string. If a trailing newline is found, it
    > is removed before duplicating. This is useful for strings
    > coming from sysfs that often include trailing whitespace due to
    > user input.

    hm, why? I doubt if any caller of this wants to retain leading and/or
    trailing spaces and/or tabs.



    \
     
     \ /
      Last update: 2014-02-05 23:21    [W:4.310 / U:0.008 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site