From 69c15729f2209b2d4ecbc95794b02bebc2b62807 Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Sat, 13 Nov 2010 22:50:03 +0000 Subject: [PATCH] Fix crash on closedown. git-svn-id: svn://localhost/ardour2/branches/3.0@8022 d708f5d6-7413-0410-9779-e7cbd77b26cf --- libs/ardour/port.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libs/ardour/port.cc b/libs/ardour/port.cc index 4ae9b03c3b..55481faa64 100644 --- a/libs/ardour/port.cc +++ b/libs/ardour/port.cc @@ -63,7 +63,9 @@ Port::Port (std::string const & n, DataType t, Flags f) /** Port destructor */ Port::~Port () { - jack_port_unregister (_engine->jack (), _jack_port); + if (_engine->jack ()) { + jack_port_unregister (_engine->jack (), _jack_port); + } } /** @return true if this port is connected to anything */