[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20140205135052.4066b67689cbf47c551d30a9@linux-foundation.org>
Date: Wed, 5 Feb 2014 13:50:52 -0800
From: Andrew Morton <akpm@...ux-foundation.org>
To: Sebastian Capella <sebastian.capella@...aro.org>
Cc: linux-kernel@...r.kernel.org, linux-mm@...ck.org,
linux-pm@...r.kernel.org, linaro-kernel@...ts.linaro.org,
patches@...aro.org, Michel Lespinasse <walken@...gle.com>,
Shaohua Li <shli@...nel.org>,
Jerome Marchand <jmarchan@...hat.com>,
Mikulas Patocka <mpatocka@...hat.com>,
Joonsoo Kim <iamjoonsoo.kim@....com>,
Joe Perches <joe@...ches.com>,
David Rientjes <rientjes@...gle.com>,
Alexey Dobriyan <adobriyan@...il.com>
Subject: Re: [PATCH v7 1/3] mm: add kstrdup_trimnl function
On Tue, 4 Feb 2014 12:43:49 -0800 Sebastian Capella <sebastian.capella@...aro.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.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists