From 93687c1491e8df144829804e7d7c142ca70d9f32 Mon Sep 17 00:00:00 2001 From: Alessandro Ranellucci Date: Thu, 1 Jan 2015 12:37:38 +0100 Subject: [PATCH] Disable Growl notifications if register() fails - this prevents a deadlock on growler->notify() --- lib/Slic3r/GUI/Notifier.pm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/Slic3r/GUI/Notifier.pm b/lib/Slic3r/GUI/Notifier.pm index 78d31de3c..d347b74b3 100644 --- a/lib/Slic3r/GUI/Notifier.pm +++ b/lib/Slic3r/GUI/Notifier.pm @@ -14,6 +14,8 @@ sub BUILD { $self->growler(Growl::GNTP->new(AppName => 'Slic3r', AppIcon => $icon)); $self->growler->register([{Name => 'SKEIN_DONE', DisplayName => 'Slicing Done'}]); }; + # if register() fails (for example because of a timeout), disable growler at all + $self->growler(undef) if $@; } }