From: Andre Noll Date: Sun, 21 Oct 2007 12:59:20 +0000 (+0200) Subject: aft.c: Remove special case code for playlist mode. X-Git-Tag: v0.3.0~274 X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=commitdiff_plain;h=cd38753609763dbc55e72a7df446837792628d6d aft.c: Remove special case code for playlist mode. --- diff --git a/aft.c b/aft.c index d77d7eaf..b9db5a81 100644 --- a/aft.c +++ b/aft.c @@ -619,6 +619,7 @@ int open_and_update_audio_file(struct osl_row *aft_row, struct audio_file_data * struct osl_object afsi_obj; struct afs_info new_afsi; int ret = get_hash_of_row(aft_row, &aft_hash); + struct afsi_change_event_data aced; if (ret < 0) return ret; @@ -648,13 +649,11 @@ int open_and_update_audio_file(struct osl_row *aft_row, struct audio_file_data * new_afsi.num_played++; new_afsi.last_played = time(NULL); save_afsi(&new_afsi, &afsi_obj); /* in-place update */ - if (afd->current_play_mode == PLAY_MODE_PLAYLIST) - ret = playlist_update_audio_file(aft_row); - else { - struct afsi_change_event_data aced = {.aft_row = aft_row, - .old_afsi = &afd->afsi}; - afs_event(AFSI_CHANGE, NULL, &aced); - } + + aced.aft_row = aft_row; + aced.old_afsi = &afd->afsi; + afs_event(AFSI_CHANGE, NULL, &aced); + return ret; err: free(afd->afhi.chunk_table);