Hi all, Greg,
libsysfs/dlist.c: _dlist_mark_move()
is missing checks for empty lists and may (and indeed, does) crash when=20
called with empty dlists.
{
if(direction)
{
- if( list->marker->next!=NULL)
+ if( list->marker && list->marker->next!=NULL)
list->marker=list->marker->next;
else
return(NULL);
}
else
{
- if( list->marker->prev!=NULL)
+ if( list->marker && list->marker->prev!=NULL)
list->marker=list->marker->prev;
else
return(NULL);