diff options
Diffstat (limited to 'src/tag')
-rw-r--r-- | src/tag/ReplayGain.cxx | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/tag/ReplayGain.cxx b/src/tag/ReplayGain.cxx index 10f2f8a32..ccdcf3fc8 100644 --- a/src/tag/ReplayGain.cxx +++ b/src/tag/ReplayGain.cxx @@ -22,6 +22,7 @@ #include "VorbisComment.hxx" #include "ReplayGainInfo.hxx" #include "util/ASCII.hxx" +#include "util/NumberParser.hxx" #include <assert.h> #include <stdlib.h> @@ -33,16 +34,16 @@ ParseReplayGainTagTemplate(ReplayGainInfo &info, const T t) const char *value; if ((value = t["replaygain_track_gain"]) != nullptr) { - info.track.gain = atof(value); + info.track.gain = ParseFloat(value); return true; } else if ((value = t["replaygain_album_gain"]) != nullptr) { - info.album.gain = atof(value); + info.album.gain = ParseFloat(value); return true; } else if ((value = t["replaygain_track_peak"]) != nullptr) { - info.track.peak = atof(value); + info.track.peak = ParseFloat(value); return true; } else if ((value = t["replaygain_album_peak"]) != nullptr) { - info.album.peak = atof(value); + info.album.peak = ParseFloat(value); return true; } else return false; |