PARA_INFO_LOG("waketime: %d:%02d\n", tm->tm_hour, tm->tm_min);
client_cmd("stop");
sleep(1);
+ ret = set_initial_volume(m, h);
+ if (ret < 0)
+ goto close_mixer;
+ /*
+ * Setting the volume invalidates the current channel setting, so we
+ * have to set it again.
+ */
+ ret = set_channel(m, h, OPT_STRING_VAL(PARA_MIXER, MIXER_CHANNEL));
+ if (ret < 0)
+ goto close_mixer;
if (fot && fo_mood && *fo_mood) {
- ret = set_initial_volume(m, h);
- if (ret < 0)
- goto close_mixer;
change_afs_mode(fo_mood);
client_cmd("play");
- ret = set_channel(m, h, OPT_STRING_VAL(PARA_MIXER, MIXER_CHANNEL));
- if (ret < 0)
- goto close_mixer;
ret = fade(m, h, fov, fot);
if (ret < 0)
goto close_mixer;