univalue: add support for real, fix percision and make it json_spirit compatible
- avoid breaking the API because of different number/percision handling
This commit is contained in:
@@ -146,8 +146,9 @@ Array RPCConvertValues(const std::string &strMethod, const std::vector<std::stri
|
||||
jVal.setBool(false);
|
||||
else
|
||||
{
|
||||
if (!jVal.read(strVal))
|
||||
throw runtime_error(string("Error parsing JSON:")+strVal);
|
||||
if (!jVal.read(strVal) || (jVal.isNull() && strVal.size() > 0))
|
||||
if(!jVal.setNumStr(strVal) || jVal.isNull())
|
||||
throw runtime_error(string("Error parsing JSON:")+strVal);
|
||||
}
|
||||
params.push_back(jVal);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user