From 4b5813051b6f7b4cd941a39b5da50d084a5f46c3 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Tue, 4 Aug 2020 11:34:05 +0200 Subject: [PATCH] unsigned long long -> uint64_t --- src/hydra-queue-runner/build-result.hh | 2 +- src/hydra-queue-runner/hydra-queue-runner.cc | 3 +-- src/hydra-queue-runner/nar-extractor.cc | 2 +- src/hydra-queue-runner/nar-extractor.hh | 2 +- src/hydra-queue-runner/queue-monitor.cc | 4 ++-- 5 files changed, 6 insertions(+), 7 deletions(-) diff --git a/src/hydra-queue-runner/build-result.hh b/src/hydra-queue-runner/build-result.hh index 4cbbaccb..a3f71ae9 100644 --- a/src/hydra-queue-runner/build-result.hh +++ b/src/hydra-queue-runner/build-result.hh @@ -32,7 +32,7 @@ struct BuildOutput std::string releaseName; - unsigned long long closureSize = 0, size = 0; + uint64_t closureSize = 0, size = 0; std::list products; diff --git a/src/hydra-queue-runner/hydra-queue-runner.cc b/src/hydra-queue-runner/hydra-queue-runner.cc index 2d616840..38bb1503 100644 --- a/src/hydra-queue-runner/hydra-queue-runner.cc +++ b/src/hydra-queue-runner/hydra-queue-runner.cc @@ -23,8 +23,7 @@ using namespace nix; namespace nix { template<> void toJSON>(std::ostream & str, const std::atomic & n) { str << n; } -template<> void toJSON>(std::ostream & str, const std::atomic & n) { str << n; } -template<> void toJSON>(std::ostream & str, const std::atomic & n) { str << n; } +template<> void toJSON>(std::ostream & str, const std::atomic & n) { str << n; } template<> void toJSON(std::ostream & str, const double & n) { str << n; } } diff --git a/src/hydra-queue-runner/nar-extractor.cc b/src/hydra-queue-runner/nar-extractor.cc index 8705e4ce..5c2cd97c 100644 --- a/src/hydra-queue-runner/nar-extractor.cc +++ b/src/hydra-queue-runner/nar-extractor.cc @@ -36,7 +36,7 @@ struct Extractor : ParseSink }).first->second; } - std::optional expectedSize; + std::optional expectedSize; std::unique_ptr hashSink; void preallocateContents(uint64_t size) override diff --git a/src/hydra-queue-runner/nar-extractor.hh b/src/hydra-queue-runner/nar-extractor.hh index d14726a3..45b2706c 100644 --- a/src/hydra-queue-runner/nar-extractor.hh +++ b/src/hydra-queue-runner/nar-extractor.hh @@ -8,7 +8,7 @@ struct NarMemberData { nix::FSAccessor::Type type; - std::optional fileSize; + std::optional fileSize; std::optional contents; std::optional sha256; }; diff --git a/src/hydra-queue-runner/queue-monitor.cc b/src/hydra-queue-runner/queue-monitor.cc index ee073b53..f1cc0ef7 100644 --- a/src/hydra-queue-runner/queue-monitor.cc +++ b/src/hydra-queue-runner/queue-monitor.cc @@ -631,8 +631,8 @@ BuildOutput State::getBuildOutputCached(Connection & conn, nix::ref BuildOutput res; res.failed = r[0][1].as() == bsFailedWithOutput; res.releaseName = r[0][2].is_null() ? "" : r[0][2].as(); - res.closureSize = r[0][3].is_null() ? 0 : r[0][3].as(); - res.size = r[0][4].is_null() ? 0 : r[0][4].as(); + res.closureSize = r[0][3].is_null() ? 0 : r[0][3].as(); + res.size = r[0][4].is_null() ? 0 : r[0][4].as(); auto products = txn.exec_params ("select type, subtype, fileSize, sha256hash, path, name, defaultPath from BuildProducts where build = $1 order by productnr",