aboutsummaryrefslogtreecommitdiffstats
path: root/src/inputPlugins/ogg_plugin.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/inputPlugins/ogg_plugin.c')
-rw-r--r--src/inputPlugins/ogg_plugin.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/inputPlugins/ogg_plugin.c b/src/inputPlugins/ogg_plugin.c
index c65de71aa..5d461586e 100644
--- a/src/inputPlugins/ogg_plugin.c
+++ b/src/inputPlugins/ogg_plugin.c
@@ -157,12 +157,16 @@ float ogg_getReplayGainScale(char ** comments) {
if(albumGainFound) {
return computeReplayGainScale(albumGain,albumPeak);
}
- return computeReplayGainScale(trackGain,trackPeak);
+ else if(trackGainFound) {
+ return computeReplayGainScale(trackGain,trackPeak);
+ }
case REPLAYGAIN_TRACK:
if(trackGainFound) {
return computeReplayGainScale(trackGain,trackPeak);
}
- return computeReplayGainScale(albumGain,albumPeak);
+ else if(albumGainFound) {
+ return computeReplayGainScale(albumGain,albumPeak);
+ }
}
return 1.0;