diff options
author | Peter Powell <petpow@saberuk.com> | 2018-04-14 16:11:57 +0100 |
---|---|---|
committer | Peter Powell <petpow@saberuk.com> | 2018-04-16 15:29:58 +0100 |
commit | 9b8dc77585ada328a306bc12bb9827f083e7cf93 (patch) | |
tree | 13f89459bd95cca9fcd23ba2a3cd36e17f85b361 /include/configreader.h | |
parent | 780dda83ba3857bc3c330d4b5d38bb251a9d879b (diff) |
Add range checking to ConfigTag::getFloat.
Diffstat (limited to 'include/configreader.h')
-rw-r--r-- | include/configreader.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/configreader.h b/include/configreader.h index dba092920..460fd342c 100644 --- a/include/configreader.h +++ b/include/configreader.h @@ -49,7 +49,7 @@ class CoreExport ConfigTag : public refcountbase /** Get the value of an option, using def if it does not exist */ unsigned long getUInt(const std::string& key, unsigned long def, unsigned long min = 0, unsigned long max = ULONG_MAX); /** Get the value of an option, using def if it does not exist */ - double getFloat(const std::string& key, double def); + double getFloat(const std::string& key, double def, double min = DBL_MIN, double max = DBL_MAX); /** Get the value of an option, using def if it does not exist */ bool getBool(const std::string& key, bool def = false); |