2
0
mirror of https://gitlab.isc.org/isc-projects/kea synced 2025-09-03 07:25:18 +00:00

[#2445] use PgSqlExchange::getColumnValue() to fetch limits

This commit is contained in:
Andrei Pavel
2022-06-29 14:05:07 +03:00
parent e844a8b7c6
commit 839fe6e008

View File

@@ -2316,7 +2316,8 @@ PgSqlLeaseMgr::checkLimits(ConstElementPtr const& user_context, StatementIndex c
&bind_array.formats_[0], 0)); &bind_array.formats_[0], 0));
ctx->conn_.checkStatementError(r, tagged_statements[stindex]); ctx->conn_.checkStatementError(r, tagged_statements[stindex]);
std::string const limits(PgSqlExchange::getRawColumnValue(r, 0, 0)); std::string limits;
PgSqlExchange::getColumnValue(r, 0, 0, limits);
return limits; return limits;
} }
@@ -2342,8 +2343,9 @@ PgSqlLeaseMgr::isJsonSupported() const {
0, 0, 0, 0, 0)); 0, 0, 0, 0, 0));
ctx->conn_.checkStatementError(r, tagged_statements[stindex]); ctx->conn_.checkStatementError(r, tagged_statements[stindex]);
std::string const json_supported(PgSqlExchange::getRawColumnValue(r, 0, 0)); bool json_supported;
return json_supported == "t"; PgSqlExchange::getColumnValue(r, 0, 0, json_supported);
return json_supported;
} }
LeaseStatsQueryPtr LeaseStatsQueryPtr