From 47a68aeb88db40da6927ce9bfb92e25c93d3719b Mon Sep 17 00:00:00 2001 From: Thierry Vignaud Date: Sat, 21 Dec 2013 04:10:36 +0100 Subject: fix segfault when WebKit creates threads for good (mga#10289) ignore SIGCHLD until WebKit has finished creating its threads --- NEWS | 2 ++ control-center | 13 +++++++++++-- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/NEWS b/NEWS index 89422ab6..e847f3da 100644 --- a/NEWS +++ b/NEWS @@ -1,3 +1,5 @@ +- fix segfault when webkit creates threads for good (mga#10289) + Version 12.45 - 12 December 2013 Thierry Vignaud - further delay event for slow machines (mga#10289) diff --git a/control-center b/control-center index 642032aa..096a21a6 100755 --- a/control-center +++ b/control-center @@ -29,6 +29,7 @@ use standalone; use common; use detect_devices; use lang; +use feature 'state'; # i18n: IMPORTANT: to get correct namespace (drakconf instead of libDrakX) BEGIN { unshift @::textdomains, 'drakconf' } @@ -700,6 +701,15 @@ my @buttons; my $offset = 15; $view = gtknew('WebKit_View', no_popup_menu => 1); +$view->signal_connect('load-finished' => sub { + state $done; + return if $done; + $done = 1; + $SIG{CHLD} = \&sig_child; + Glib::Timeout->add(100, sub { sig_child('CHLD', 1); 1 }); + load_program() if $program; +}); +$view->signal_connect('web-view-ready' => sub { warn ">> web-view-ready\n"; 1}); # so that it exists when building steps: my $banner_notebook = Gtk2::Notebook->new; build_list(); @@ -1091,9 +1101,8 @@ $SIG{TERM} = \&quit_global; $window_splash->destroy; undef $window_splash; -Glib::Timeout->add(1000, sub { $SIG{CHLD} = \&sig_child; sig_child('CHLD', 1); 1 }); -if ($program) { +sub load_program() { if (my $sub = $tool_callbacks{$program}) { Glib::Timeout->add(1100, sub { $sub->(); 0 }); } else { -- cgit v1.2.1