From aac9cbc534ab57a5471b121523bd8308e857c228 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Thu, 20 Dec 2012 23:28:25 +0000 Subject: Fix crash on bad delete events. git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@4867 a436a847-0d15-0410-975c-d299462d15a1 --- src/server/events/Delete.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/server/events/Delete.cpp b/src/server/events/Delete.cpp index e4878f4e..2504e837 100644 --- a/src/server/events/Delete.cpp +++ b/src/server/events/Delete.cpp @@ -122,8 +122,9 @@ Delete::execute(ProcessContext& context) _disconnect_event->execute(context); } - GraphImpl* parent = _block ? _block->parent_graph() : _port->parent_graph(); + GraphImpl* parent = _block ? _block->parent_graph() : NULL; if (_port) { + parent = _port->parent_graph(); _engine.maid()->dispose(parent->external_ports()); parent->external_ports(_ports_array); -- cgit v1.2.1