-
- for(track = first;
- track;
- track = next_track)
- {
- next_track = track->next;
-
- if(track->record)
- {
- if(track->previous)
- {
- change_modules(number_of(track->previous), number_of(track), 1);
-
- swap(track->previous, track);
- result = 1;
- }
+ Track *next = first;
+ while( next ) {
+ Track *track = next; next = track->next;
+ if( !track->record ) continue;
+ if( track->previous ) {
+ change_modules(number_of(track->previous), number_of(track), 1);
+ swap(track->previous, track);
+ result = 1;