From 8f7f419adcfcd6cd7557b82266b064ed242793ad Mon Sep 17 00:00:00 2001 From: David Robillard Date: Fri, 29 Jun 2012 23:06:19 +0000 Subject: Fix crashes caused by events attempting to respond to deleted clients (fix #842). This one mainly manifested when using ingenish from the command line since the client is so short lived. git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@4503 a436a847-0d15-0410-975c-d299462d15a1 --- src/server/Engine.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/server/Engine.cpp') diff --git a/src/server/Engine.cpp b/src/server/Engine.cpp index c5a7bddd..85ca530c 100644 --- a/src/server/Engine.cpp +++ b/src/server/Engine.cpp @@ -218,8 +218,9 @@ Engine::activate() make_pair(uris.ingen_canvasY, Resource::Property(forge.make(32.0f), Resource::EXTERNAL))); + SharedPtr respondee; execute_and_delete_event( - context, new Events::CreatePort(*this, NULL, -1, 0, + context, new Events::CreatePort(*this, respondee, -1, 0, "/control_in", false, in_properties)); // Add control out @@ -236,7 +237,7 @@ Engine::activate() Resource::Property(forge.make(32.0f), Resource::EXTERNAL))); execute_and_delete_event( - context, new Events::CreatePort(*this, NULL, -1, 0, + context, new Events::CreatePort(*this, respondee, -1, 0, "/control_out", true, out_properties)); } -- cgit v1.2.1