From c37ebd2d0bb9ad6d2cf6d4541a1de523b584b36e Mon Sep 17 00:00:00 2001 From: Daniel Seither Date: Thu, 30 Jul 2015 19:30:09 +0200 Subject: tests: Add missing overrides --- src/tests/test_rng.cpp | 2 +- src/tests/test_rng.h | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/tests/test_rng.cpp b/src/tests/test_rng.cpp index 81a539f1e..d129ed208 100644 --- a/src/tests/test_rng.cpp +++ b/src/tests/test_rng.cpp @@ -31,7 +31,7 @@ RandomNumberGenerator* get_rng(const std::string& algo_str, const std::string& i public: AllOnce_RNG(const std::vector& in) : Fixed_Output_RNG(in) {} - Botan::secure_vector random_vec(size_t) + Botan::secure_vector random_vec(size_t) override { Botan::secure_vector vec(this->remaining()); this->randomize(vec.data(), vec.size()); diff --git a/src/tests/test_rng.h b/src/tests/test_rng.h index bf4032699..f1d40f7f1 100644 --- a/src/tests/test_rng.h +++ b/src/tests/test_rng.h @@ -18,7 +18,7 @@ using Botan::byte; class Fixed_Output_RNG : public Botan::RandomNumberGenerator { public: - bool is_seeded() const { return !buf.empty(); } + bool is_seeded() const override { return !buf.empty(); } byte random() { @@ -30,22 +30,22 @@ class Fixed_Output_RNG : public Botan::RandomNumberGenerator return out; } - void reseed(size_t) {} + void reseed(size_t) override {} - void randomize(byte out[], size_t len) + void randomize(byte out[], size_t len) override { for(size_t j = 0; j != len; j++) out[j] = random(); } - void add_entropy(const byte b[], size_t s) + void add_entropy(const byte b[], size_t s) override { buf.insert(buf.end(), b, b + s); } - std::string name() const { return "Fixed_Output_RNG"; } + std::string name() const override { return "Fixed_Output_RNG"; } - void clear() throw() {} + void clear() throw() override {} Fixed_Output_RNG(const std::vector& in) { -- cgit v1.2.3