git.openpandora.org
/
pandora-kernel.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
154f5e3
)
lib: bitmap: simplify bitmap_parselist
author
Rasmus Villemoes
<linux@rasmusvillemoes.dk>
Wed, 6 Aug 2014 23:10:12 +0000
(16:10 -0700)
committer
Linus Torvalds
<torvalds@linux-foundation.org>
Thu, 7 Aug 2014 01:01:26 +0000
(18:01 -0700)
We want len to be the index of the first '\n', or the length of the
string if there is no newline. This is a good example of the usefulness
of strchrnul(). Use that instead, thus eliminating a branch and a call
to strlen().
Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
lib/bitmap.c
patch
|
blob
|
history
diff --cc
lib/bitmap.c
Simple merge