Fix warnings and dependencies

This commit is contained in:
eelke 2025-02-23 16:52:39 +01:00
parent 86a9a0d709
commit ee86327869
14 changed files with 38 additions and 43 deletions

View file

@ -5,12 +5,8 @@
#include <libpq-fe.h>
#include <QString>
#include <vector>
#include <codecvt>
#include <memory>
#include <fmt/format.h>
#include "Pgsql_Canceller.h"
#include "Pgsql_Result.h"

View file

@ -116,7 +116,7 @@ void Params::clear()
void Params::appendValues(const t_paramValues &r)
{
const int n = static_cast<int>(r.size());
const int ofs = m_paramValues.size();
const size_t ofs = m_paramValues.size();
m_paramValues.reserve(ofs + n);
for (int i = 0; i < n; ++i) {
if (r[i]) {

View file

@ -128,7 +128,7 @@ Value::operator int64_t() const
if (m_val == nullptr)
return 0LL;
const int len = std::strlen(m_val);
const size_t len = std::strlen(m_val);
if (len > 0) {
char *endptr = nullptr;
int64_t result = std::strtoll(m_val, &endptr, 10);
@ -136,7 +136,6 @@ Value::operator int64_t() const
return result;
}
throw std::runtime_error("Value conversion to int64_t failed");
// return std::strtoll(m_val, nullptr, 10);
}
Value::operator bool() const

View file

@ -7,7 +7,7 @@
CONFIG += staticlib
QT += core
greaterThan(QT_MAJOR_VERSION, 4): QT += widgets sql
greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
TARGET = pgsql
TEMPLATE = lib