potential fix for truncated float representation
This commit is contained in:
@@ -34,6 +34,7 @@
|
|||||||
namespace ebusd {
|
namespace ebusd {
|
||||||
|
|
||||||
using std::dec;
|
using std::dec;
|
||||||
|
using std::defaultfloat;
|
||||||
using std::hex;
|
using std::hex;
|
||||||
using std::fixed;
|
using std::fixed;
|
||||||
using std::setfill;
|
using std::setfill;
|
||||||
@@ -731,7 +732,7 @@ result_t NumberDataType::readSymbols(size_t offset, size_t length, const SymbolS
|
|||||||
if (result != RESULT_OK) {
|
if (result != RESULT_OK) {
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
*output << setw(0) << dec; // initialize output
|
*output << defaultfloat << setw(0) << dec; // initialize output
|
||||||
|
|
||||||
if (!hasFlag(REQ) && value == m_replacement) {
|
if (!hasFlag(REQ) && value == m_replacement) {
|
||||||
if (outputFormat & OF_JSON) {
|
if (outputFormat & OF_JSON) {
|
||||||
|
|||||||
Reference in New Issue
Block a user