projects
/
GitHub
/
LineageOS
/
android_kernel_samsung_universal7580.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
efa7e86
)
Fix ZERO_OR_NULL_PTR(ZERO_SIZE_PTR)
author
Roland Dreier
<rdreier@cisco.com>
Fri, 20 Jul 2007 19:13:20 +0000
(12:13 -0700)
committer
Linus Torvalds
<torvalds@woody.linux-foundation.org>
Fri, 20 Jul 2007 19:33:44 +0000
(12:33 -0700)
The comparison with ZERO_SIZE_PTR in ZERO_OR_NULL_PTR() needs to be <=
(not just <) so that ZERO_OR_NULL_PTR(ZERO_SIZE_PTR) is 1.
Signed-off-by: Roland Dreier <rolandd@cisco.com>
[ Duh! - Linus ]
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
include/linux/slab.h
patch
|
blob
|
blame
|
history
diff --git
a/include/linux/slab.h
b/include/linux/slab.h
index 7d0ecc1659f063df2f69550aa3d3b157cd36f1fd..d859354b9e51ea73952b31371b21172e2622097e 100644
(file)
--- a/
include/linux/slab.h
+++ b/
include/linux/slab.h
@@
-40,7
+40,7
@@
*/
#define ZERO_SIZE_PTR ((void *)16)
-#define ZERO_OR_NULL_PTR(x) ((unsigned long)(x) < \
+#define ZERO_OR_NULL_PTR(x) ((unsigned long)(x) <
=
\
(unsigned long)ZERO_SIZE_PTR)
/*