From 8565e6cc107b65456e9288dc7cbd5facfbac6707 Mon Sep 17 00:00:00 2001 From: John Haddon Date: Thu, 7 Dec 2023 12:41:08 +0000 Subject: [PATCH] switch : don't do compute in plugInputChanged --- src/Gaffer/Switch.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/Gaffer/Switch.cpp b/src/Gaffer/Switch.cpp index 65c7ec577bb..e5d7896b71b 100644 --- a/src/Gaffer/Switch.cpp +++ b/src/Gaffer/Switch.cpp @@ -296,7 +296,6 @@ void Switch::plugInputChanged( Plug *plug ) { try { - std::cerr << "Switch::plugInputChanged " << fullName() << std::endl; if( plug == indexPlug() || plug == enabledPlug() ) { updateInternalConnection(); @@ -441,7 +440,7 @@ void Switch::updateInternalConnection() std::cerr << "Switch::updateInternalConnection 3.5 " << fullName() << std::endl; - Plug *in = const_cast( oppositePlug( out, Context::current() ) ); + Plug *in = const_cast( oppositePlug( out, nullptr ) ); std::cerr << "Switch::updateInternalConnection 4 " << fullName() << std::endl; out->setInput( in ); std::cerr << "Switch::updateInternalConnection 5 " << fullName() << std::endl;