0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2025-01-01 02:14:13 +01:00

ircd::json: Fix error.

This commit is contained in:
Jason Volk 2017-10-03 13:20:43 -07:00
parent fccfa03308
commit fb498ed2f2

View file

@ -167,7 +167,8 @@ ircd::json::string(T&&... t)
serialized(std::forward<T>(t)...) serialized(std::forward<T>(t)...)
}; };
std::string ret(size, char{}); std::string ret;
ret.resize(size, char{});
const auto buf{const_cast<char *>(ret.data())}; const auto buf{const_cast<char *>(ret.data())};
const auto max{ret.size() + 1}; const auto max{ret.size() + 1};