ReplayGainInfo: don't use array in struct ReplayGainInfo

Declare two named elements.  An enum should not be used as an array
index, as this is error prone.
This commit is contained in:
Max Kellermann
2016-11-24 16:45:56 +01:00
parent 1261327fa6
commit 25e58df5e0
9 changed files with 29 additions and 34 deletions

View File

@@ -805,8 +805,8 @@ MadDecoder::DecodeFirstFrame(Tag **tag)
lame.track_gain) {
ReplayGainInfo rgi;
rgi.Clear();
rgi.tuples[REPLAY_GAIN_TRACK].gain = lame.track_gain;
rgi.tuples[REPLAY_GAIN_TRACK].peak = lame.peak;
rgi.track.gain = lame.track_gain;
rgi.track.peak = lame.peak;
client->SubmitReplayGain(&rgi);
}
}