diff options
author | David Robillard <d@drobilla.net> | 2008-12-20 20:28:04 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2008-12-20 20:28:04 +0000 |
commit | 76f6fcfad68d88728bb1a04b193029aa9e46e976 (patch) | |
tree | 271ca830393f9b6dc5241b1ff152905902aaeced /src/engine/Driver.hpp | |
parent | 72c6d069df26396436c653532702a4f96f901fba (diff) | |
download | ingen-76f6fcfad68d88728bb1a04b193029aa9e46e976.tar.gz ingen-76f6fcfad68d88728bb1a04b193029aa9e46e976.tar.bz2 ingen-76f6fcfad68d88728bb1a04b193029aa9e46e976.zip |
Fix deregistration of Jack ports, associated memory leaks. Hopefully a fix for #294 and #305).
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@1877 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/engine/Driver.hpp')
-rw-r--r-- | src/engine/Driver.hpp | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/engine/Driver.hpp b/src/engine/Driver.hpp index a11fffba..a2ca6b15 100644 --- a/src/engine/Driver.hpp +++ b/src/engine/Driver.hpp @@ -20,6 +20,7 @@ #include <string> #include <boost/utility.hpp> +#include "raul/Deletable.hpp" #include "interface/DataType.hpp" #include "DuplexPort.hpp" @@ -38,12 +39,14 @@ class DuplexPort; * * \ingroup engine */ -class DriverPort : boost::noncopyable { +class DriverPort : boost::noncopyable, public Raul::Deletable { public: virtual ~DriverPort() {} /** Set the name of the system port */ virtual void set_name(const std::string& name) = 0; + + virtual void unregister() = 0; bool is_input() const { return _patch_port->is_input(); } DuplexPort* patch_port() const { return _patch_port; } @@ -86,8 +89,9 @@ public: virtual DriverPort* driver_port(const Raul::Path& path) = 0; - virtual void add_port(DriverPort* port) = 0; - virtual DriverPort* remove_port(const Raul::Path& path) = 0; + virtual void add_port(DriverPort* port) = 0; + + virtual Raul::List<DriverPort*>::Node* remove_port(const Raul::Path& path) = 0; protected: DataType _type; |