aboutsummaryrefslogtreecommitdiff
path: root/lib/argv_split.c
AgeCommit message (Collapse)AuthorFilesLines
2007-10-20LIB: Replace inappropriate include of <linux/bug.h>Robert P. J. Day1-1/+2
Replace an irrelevant include of bug.h with the more appropriate includes of slab.h and module.h. it's not as if the original inclusion is an error, it's simply not related to the contents of that source file, while the other two are. compile-tested on i386. Signed-off-by: Robert P. J. Day <[email protected]> Signed-off-by: Adrian Bunk <[email protected]>
2007-10-17argv_split: allow argv_split to handle NULL pointer in argcp parameter ↵Neil Horman1-1/+3
gracefully It would be nice if the argv_split library function could gracefully handle a NULL pointer in the argcp parameter, so as to allow functions using it that did not care about the value of argc to not have to declare a useless variable. This patch accomplishes that. Tested by me, with successful results. Signed-off-by: Neil Horman <[email protected]> Acked-by: Jeremy Fitzhardinge <[email protected]> Cc: Satyam Sharma <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2007-07-18add argv_split()Jeremy Fitzhardinge1-0/+105
argv_split() is a helper function which takes a string, splits it at whitespace, and returns a NULL-terminated argv vector. This is deliberately simple - it does no quote processing of any kind. [ Seems to me that this is something which is already being done in the kernel, but I couldn't find any other implementations, either to steal or replace. Keep an eye out. ] Signed-off-by: Jeremy Fitzhardinge <[email protected]> Signed-off-by: Chris Wright <[email protected]> Cc: Andrew Morton <[email protected]> Cc: Randy Dunlap <[email protected]>