Bug 123201 - linux list.h file, all the function has not check the point
Summary: linux list.h file, all the function has not check the point
Status: NEW
Alias: None
Product: Other
Classification: Unclassified
Component: Other (show other bugs)
Hardware: All Linux
: P1 normal
Assignee: other_other
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-07-12 09:50 UTC by nemohan
Modified: 2016-07-17 22:15 UTC (History)
2 users (show)

See Also:
Kernel Version: 2.6.32 4.6 and all linux version
Subsystem:
Regression: No
Bisected commit-id:


Attachments

Description nemohan 2016-07-12 09:50:36 UTC
in list.h file, sone functions like follow
static inline void __list_del(struct list_head * prev, struct list_head * next)
{
	next->prev = prev;
	prev->next = next;
}
if i set the prev =  NULL, or prev->next=NULL, the code does not check this situation, it will cause the kernel or application run to an unpredictable status
Comment 1 Alexey Dobriyan 2016-07-17 22:14:26 UTC
It will, so don't do it.
Comment 2 Alexey Dobriyan 2016-07-17 22:15:21 UTC
I swear it was possible for anyone to close the bug.

Note You need to log in before you can comment on or make changes to this bug.