equal
deleted
inserted
replaced
6 #include "openttd.h" |
6 #include "openttd.h" |
7 #include "fsmport.h" |
7 #include "fsmport.h" |
8 |
8 |
9 FSMPortClass::~FSMPortClass() |
9 FSMPortClass::~FSMPortClass() |
10 { |
10 { |
11 for (uint i = 0; i < nof_elements; i++) { |
11 for (uint i = 0; i < num_positions; i++) { |
12 FSMState *current = layout[i].next; |
12 FSMCommand *current = layout[i].next; |
13 while (current != NULL) { |
13 while (current != NULL) { |
14 FSMState *next = current->next; |
14 FSMCommand *next = current->next; |
15 free(current); |
15 free(current); |
16 current = next; |
16 current = next; |
17 }; |
17 }; |
18 } |
18 } |
19 free(layout); |
19 free(layout); |