clear
This commit is contained in:
parent
0368a7af28
commit
0069229806
@ -66,9 +66,9 @@ struct car* clear_train(struct car* first, const char* target) {
|
||||
while(prev->next->next != NULL){
|
||||
int x = strcmp(first->value, target);
|
||||
if(x == 0){
|
||||
first = NULL;
|
||||
first = prev->next;
|
||||
free(prev);
|
||||
//first = NULL;
|
||||
first = first->next;
|
||||
free(first);
|
||||
return first;
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user