From ac61104df7df1b452666a037aeac55d5b71da85d Mon Sep 17 00:00:00 2001 From: Thomas Holder Date: Fri, 23 Aug 2019 17:25:01 +0200 Subject: Eliminate clang warnings -Winfinite-recursion -Wpessimizing-move -Wunused-label -Wunneeded-internal-declaration -Wself-assign-overloaded -Wunused-const-variable (some) -Wsometimes-uninitialized (some) --- src/debug/event.h | 2 +- src/debug/simple-event.h | 2 +- src/debug/timestamp.cpp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) (limited to 'src/debug') diff --git a/src/debug/event.h b/src/debug/event.h index db0146b4b..3bc6089f0 100644 --- a/src/debug/event.h +++ b/src/debug/event.h @@ -46,7 +46,7 @@ public: : name(n), value(std::move(v)) {} PropertyPair(char const *n, char const *v) : name(n), - value(std::move(std::make_shared(v))) {} + value(std::make_shared(v)) {} char const *name; std::shared_ptr value; diff --git a/src/debug/simple-event.h b/src/debug/simple-event.h index 983ff5346..c753ae1fe 100644 --- a/src/debug/simple-event.h +++ b/src/debug/simple-event.h @@ -48,7 +48,7 @@ protected: _properties.push_back(PropertyPair(name, std::move(value))); } void _addProperty(char const *name, char const *value) { - _addProperty(name, std::move(std::make_shared(value))); + _addProperty(name, std::make_shared(value)); } void _addProperty(char const *name, long value) { _addFormattedProperty(name, "%ld", value); diff --git a/src/debug/timestamp.cpp b/src/debug/timestamp.cpp index 619c4a18a..14d211ef3 100644 --- a/src/debug/timestamp.cpp +++ b/src/debug/timestamp.cpp @@ -28,7 +28,7 @@ std::shared_ptr timestamp() { gchar *value = g_strdup_printf( "%d.%06d", static_cast(timestamp.tv_sec), static_cast(timestamp.tv_usec) ); std::shared_ptr result = std::make_shared(value); g_free(value); - return std::move(result); + return result; } } -- cgit v1.2.3