This commit is contained in:
Maryna Kravtsova 2020-11-02 17:01:30 +01:00
parent 7bd7f9c076
commit bd7d9eedb8

View File

@ -45,7 +45,7 @@ void print_train(struct car* first) {
void cancel_train(struct car* first) {
if(first == NULL){
return 0;
return;
}
if(first->next != NULL){
cancel_train(first->next);
@ -67,7 +67,7 @@ struct car* clear_train(struct car* first, const char* target) {
}
int x;
if(first->next == NULL){
x = strcmp(first->value; target);
x = strcmp(first->value, target);
if(x == 0){
free(first);
return 0;