28 if(!node)
return NULL;
53 if(!head || !pos)
return NULL;
57 if(!node)
return NULL;
86 if (!pos || !head)
return -1;
87 if (pos == head)
return -1;
89 if(free_function && pos->
data)
90 (*free_function)(pos->
data);
119 if (!head)
return NULL;
121 for (node=head->
flink; node!=NULL; node=node->
flink) {
124 if((compare && (*compare)(node->
data, data)==0))
126 else if (node->
data==data)
147 if (!head)
return -1;
149 for(node=head; node!=NULL; ) {
150 tmpnode = node->
flink;
152 if(free_function!=NULL && node->
data!=NULL)
153 (*free_function)(node->
data);
177 while((head=head->
flink))
212 for ( pos=head; pos->
flink!=NULL; pos=pos->
flink ) {}
213 if ( pos->
blink==pos )
return NULL;
248 if(pos && pos->
blink!=NULL && pos!=head && pos->
blink!=head && pos->
blink!=pos )
267 if(!head1 || !head2 || !head1->
blink || !head2->
flink)