summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThierry Vignaud <thierry.vignaud@gmail.com>2017-05-30 18:10:03 +0200
committerThierry Vignaud <thierry.vignaud@gmail.com>2017-05-30 18:16:16 +0200
commitd5d6d77e981dbe8a514d6b48ced4ed680bad0abf (patch)
tree21483a843b663034aae7133d07442ac5e964a260
parent26377d87ae81f4cae391ffe5c9dac8723b6643b4 (diff)
downloaddrakx-d5d6d77e981dbe8a514d6b48ced4ed680bad0abf.tar
drakx-d5d6d77e981dbe8a514d6b48ced4ed680bad0abf.tar.gz
drakx-d5d6d77e981dbe8a514d6b48ced4ed680bad0abf.tar.bz2
drakx-d5d6d77e981dbe8a514d6b48ced4ed680bad0abf.tar.xz
drakx-d5d6d77e981dbe8a514d6b48ced4ed680bad0abf.zip
fix crash introduced in 17.77 (mga#20956)
Depending on machine speed/slowness, signals will not be fired in the order expected and Repaint() will be called before global variable $cairo is set by draw(). This can be reproduced by making $timer to happens much faster than every 120ms so that it happens before the first call to draw() This workaround fix the bug introduced in commit 1a30f422b41250e338d2c1d209aec1b64204c8e0 But it would probably be saner to get rid of the $cairo global variable and to create a Cairo context in every Repaint() caller instead...
-rw-r--r--perl-install/NEWS3
-rwxr-xr-xperl-install/standalone/drakclock1
2 files changed, 4 insertions, 0 deletions
diff --git a/perl-install/NEWS b/perl-install/NEWS
index 7da8275d9..67536cff2 100644
--- a/perl-install/NEWS
+++ b/perl-install/NEWS
@@ -1,3 +1,6 @@
+- drakclock:
+ o fix crash introduced in 17.77 (mga#20956)
+
Version 17.82 - 6 May 2017
- drakboot:
diff --git a/perl-install/standalone/drakclock b/perl-install/standalone/drakclock
index 3f4fe2e84..ed0ce940e 100755
--- a/perl-install/standalone/drakclock
+++ b/perl-install/standalone/drakclock
@@ -250,6 +250,7 @@ sub get_server() {
}
sub update_time() {
my (undef, undef, undef, $mday, $mon, $year) = localtime(time());
+ return 1 if !$cairo;
$year += 1900;
my $old_its_reset = $its_reset;
$its_reset = 1;