diff --git a/src/loaders/svg/tvgSvgUtil.cpp b/src/loaders/svg/tvgSvgUtil.cpp index 11c861f5..7fb108bc 100644 --- a/src/loaders/svg/tvgSvgUtil.cpp +++ b/src/loaders/svg/tvgSvgUtil.cpp @@ -137,11 +137,13 @@ float svgUtilStrtof(const char *nPtr, char **endPtr) pow10 *= 10ULL; } } + } else if (isspace(*iter)) { //skip if there is a space after the dot. + a = iter; + goto success; } + val += static_cast(decimalPart) / static_cast(pow10); a = iter; - //skip if there is a space after the dot. - if (isspace(*a)) goto success; } //Optional: exponent