diff --git a/benchmark/bench_actor.cpp b/benchmark/bench_actor.cpp index 674ca33e3..846dc9f39 100644 --- a/benchmark/bench_actor.cpp +++ b/benchmark/bench_actor.cpp @@ -10,6 +10,7 @@ #include "td/actor/PromiseFuture.h" #include "td/utils/common.h" +#include "td/utils/crypto.h" #include "td/utils/logging.h" #if TD_MSVC @@ -266,6 +267,8 @@ class QueryBench : public td::Benchmark { }; int main() { + td::init_openssl_threads(); + SET_VERBOSITY_LEVEL(VERBOSITY_NAME(DEBUG)); bench(RingBench<4>(504, 0)); bench(RingBench<3>(504, 0)); @@ -285,5 +288,4 @@ int main() { bench(RingBench<0>(504, 2)); bench(RingBench<1>(504, 2)); bench(RingBench<2>(504, 2)); - return 0; } diff --git a/benchmark/bench_crypto.cpp b/benchmark/bench_crypto.cpp index a4482f59b..c7d34adb4 100644 --- a/benchmark/bench_crypto.cpp +++ b/benchmark/bench_crypto.cpp @@ -366,5 +366,4 @@ int main() { td::bench(SHA1Bench()); td::bench(Crc32Bench()); td::bench(Crc64Bench()); - return 0; } diff --git a/benchmark/bench_db.cpp b/benchmark/bench_db.cpp index aee56f610..bdc3bad81 100644 --- a/benchmark/bench_db.cpp +++ b/benchmark/bench_db.cpp @@ -238,5 +238,4 @@ int main() { bench(TdKvBench>("BinlogKeyValue")); bench(TdKvBench>("BinlogKeyValue")); bench(SeqKvBench()); - return 0; } diff --git a/benchmark/bench_handshake.cpp b/benchmark/bench_handshake.cpp index 376175ffa..23ca5c647 100644 --- a/benchmark/bench_handshake.cpp +++ b/benchmark/bench_handshake.cpp @@ -74,5 +74,4 @@ class HandshakeBench : public Benchmark { int main() { SET_VERBOSITY_LEVEL(VERBOSITY_NAME(DEBUG)); td::bench(td::HandshakeBench()); - return 0; } diff --git a/benchmark/bench_log.cpp b/benchmark/bench_log.cpp index 63807b2fd..0f778e753 100644 --- a/benchmark/bench_log.cpp +++ b/benchmark/bench_log.cpp @@ -160,5 +160,4 @@ int main() { #endif td::bench(IostreamWriteBench()); td::bench(FILEWriteBench()); - return 0; } diff --git a/benchmark/bench_misc.cpp b/benchmark/bench_misc.cpp index 84c4465c2..f87d2af3d 100644 --- a/benchmark/bench_misc.cpp +++ b/benchmark/bench_misc.cpp @@ -391,5 +391,4 @@ int main() { #if TD_LINUX || TD_ANDROID || TD_TIZEN td::bench(td::SemBench()); #endif - return 0; } diff --git a/benchmark/bench_queue.cpp b/benchmark/bench_queue.cpp index 75241894a..f8dedbe72 100644 --- a/benchmark/bench_queue.cpp +++ b/benchmark/bench_queue.cpp @@ -974,6 +974,4 @@ int main() { // BENCH_Q(BufferQueue, 100); // BENCH_Q(BufferQueue, 10); // BENCH_Q(BufferQueue, 1); - - return 0; } diff --git a/benchmark/bench_tddb.cpp b/benchmark/bench_tddb.cpp index 26f358c70..05628792f 100644 --- a/benchmark/bench_tddb.cpp +++ b/benchmark/bench_tddb.cpp @@ -112,5 +112,4 @@ class MessagesDbBench : public Benchmark { int main() { SET_VERBOSITY_LEVEL(VERBOSITY_NAME(WARNING)); bench(td::MessagesDbBench()); - return 0; } diff --git a/benchmark/rmdir.cpp b/benchmark/rmdir.cpp index 2b30b1eea..0c573e326 100644 --- a/benchmark/rmdir.cpp +++ b/benchmark/rmdir.cpp @@ -26,5 +26,4 @@ int main(int argc, char *argv[]) { //} }); LOG(INFO) << status << ": " << cnt; - return 0; } diff --git a/benchmark/wget.cpp b/benchmark/wget.cpp index 4bd4e9dcb..7aa596d10 100644 --- a/benchmark/wget.cpp +++ b/benchmark/wget.cpp @@ -40,5 +40,4 @@ int main(int argc, char *argv[]) { // empty } scheduler->finish(); - return 0; }