clear
This commit is contained in:
parent
68689e212a
commit
79ffc56811
@ -87,8 +87,8 @@ struct car* clear_train(struct car* first, const char* target) {
|
|||||||
struct car* prev = NULL;
|
struct car* prev = NULL;
|
||||||
if(first == this){
|
if(first == this){
|
||||||
first = this->next;
|
first = this->next;
|
||||||
this->next = NULL;
|
|
||||||
free(this);
|
free(this);
|
||||||
|
this->next = NULL;
|
||||||
return first;
|
return first;
|
||||||
}
|
}
|
||||||
while(curr != this){
|
while(curr != this){
|
||||||
|
Loading…
Reference in New Issue
Block a user