aboutsummaryrefslogtreecommitdiffstats
path: root/src/shared
diff options
context:
space:
mode:
authorDenis Shienkov <denis.shienkov@gmail.com>2021-11-27 14:53:07 +0300
committerDenis Shienkov <denis.shienkov@gmail.com>2021-12-01 15:41:45 +0000
commit712964ef2485a2fc66a791209cb8ab5e3f4ca0d0 (patch)
tree9ebdeec2cae4770f8317b7e5d5245a79c3a2f655 /src/shared
parent276ddf9f87ee513440bbb72473b48b69eb0319a5 (diff)
Add missing std:: namespace for all functions from <cstdio> library
Change-Id: Ia5c14b86e5e0952dbebf103c5355f49e41158cba Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Diffstat (limited to 'src/shared')
-rw-r--r--src/shared/json/json.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/shared/json/json.cpp b/src/shared/json/json.cpp
index eb27d6296..7ab85cba5 100644
--- a/src/shared/json/json.cpp
+++ b/src/shared/json/json.cpp
@@ -3757,7 +3757,7 @@ static void valueToJson(const Base *b, const Value &v, std::string &json, int in
// +2 to format to ensure the expected precision
const int n = std::numeric_limits<double>::digits10 + 2;
char buf[30] = {0};
- sprintf(buf, "%.*g", n, d);
+ std::sprintf(buf, "%.*g", n, d);
// Hack:
if (buf[0] == '-' && buf[1] == '0' && buf[2] == '\0')
json += "0";
@@ -4719,7 +4719,7 @@ int Base::reserveSpace(uint32_t dataSize, int posInTable, uint32_t numItems, boo
{
// assert(posInTable >= 0 && posInTable <= (int)length);
if (size + dataSize >= Value::MaxSize) {
- fprintf(stderr, "Json: Document too large to store in data structure %d %d %d\n", (uint32_t)size, dataSize, Value::MaxSize);
+ std::fprintf(stderr, "Json: Document too large to store in data structure %d %d %d\n", (uint32_t)size, dataSize, Value::MaxSize);
return 0;
}