From 784dc03a78dc338b45111ebdca45371dfaaa6fa9 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Tue, 23 Feb 2010 18:45:26 +0000 Subject: Fix various code issues discovered by cppcheck. git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@2484 a436a847-0d15-0410-975c-d299462d15a1 --- src/engine/events/Connect.cpp | 2 ++ src/engine/events/SendBinding.hpp | 3 ++- src/engine/events/SendPortActivity.hpp | 3 ++- src/engine/events/SendPortValue.hpp | 3 ++- src/engine/events/SetMetadata.hpp | 1 - 5 files changed, 8 insertions(+), 4 deletions(-) (limited to 'src/engine/events') diff --git a/src/engine/events/Connect.cpp b/src/engine/events/Connect.cpp index 6d096bbd..fac11965 100644 --- a/src/engine/events/Connect.cpp +++ b/src/engine/events/Connect.cpp @@ -49,6 +49,8 @@ Connect::Connect(Engine& engine, SharedPtr request, SampleCount timesta , _patch(NULL) , _src_port(NULL) , _dst_port(NULL) + , _src_output_port(NULL) + , _dst_input_port(NULL) , _compiled_patch(NULL) , _patch_listnode(NULL) , _port_listnode(NULL) diff --git a/src/engine/events/SendBinding.hpp b/src/engine/events/SendBinding.hpp index 837d3463..b11ecfd2 100644 --- a/src/engine/events/SendBinding.hpp +++ b/src/engine/events/SendBinding.hpp @@ -65,10 +65,11 @@ public: } } - inline void operator=(const SendBinding& ev) { + inline SendBinding& operator=(const SendBinding& ev) { _port = ev._port; _type = ev._type; _num = ev._num; + return *this; } void post_process(); diff --git a/src/engine/events/SendPortActivity.hpp b/src/engine/events/SendPortActivity.hpp index 4481d8fc..61e0113a 100644 --- a/src/engine/events/SendPortActivity.hpp +++ b/src/engine/events/SendPortActivity.hpp @@ -51,8 +51,9 @@ public: { } - inline void operator=(const SendPortActivity& ev) { + inline SendPortActivity& operator=(const SendPortActivity& ev) { _port = ev._port; + return *this; } void post_process(); diff --git a/src/engine/events/SendPortValue.hpp b/src/engine/events/SendPortValue.hpp index 8cbb3cbe..2b390832 100644 --- a/src/engine/events/SendPortValue.hpp +++ b/src/engine/events/SendPortValue.hpp @@ -58,11 +58,12 @@ public: { } - inline void operator=(const SendPortValue& ev) { + inline SendPortValue& operator=(const SendPortValue& ev) { _port = ev._port; _omni = ev._omni; _voice_num = ev._voice_num; _value = ev._value; + return *this; } void post_process(); diff --git a/src/engine/events/SetMetadata.hpp b/src/engine/events/SetMetadata.hpp index ee7d9d42..c13505cc 100644 --- a/src/engine/events/SetMetadata.hpp +++ b/src/engine/events/SetMetadata.hpp @@ -114,7 +114,6 @@ private: std::string _error_predicate; bool _create; bool _is_meta; - bool _success; SharedPtr _old_bindings; }; -- cgit v1.2.1