From 7f82bb3196f18bfe9d3c5d360dea959c7c172ff5 Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Thu, 3 Apr 2008 04:51:16 +0000 Subject: [PATCH] =?UTF-8?q?Bug=20448943=20=E2=80=93=20g=5Ftimeout=5Fadd=5F?= =?UTF-8?q?seconds()=20problems?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 2008-04-03 Matthias Clasen Bug 448943 – g_timeout_add_seconds() problems * glib/gmain.c (g_timeout_set_expiration): Prevent expiration time going negative. Reported by Cody Russell, analyzed by Olivier Crete, patch by Sjoerd Simons. svn path=/trunk/; revision=6814 --- ChangeLog | 8 ++++++++ glib/gmain.c | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index e04b6a9fc..aac81ebd1 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2008-04-03 Matthias Clasen + + Bug 448943 – g_timeout_add_seconds() problems + + * glib/gmain.c (g_timeout_set_expiration): Prevent expiration + time going negative. Reported by Cody Russell, analyzed by + Olivier Crete, patch by Sjoerd Simons. + 2008-04-03 Matthias Clasen Bug 525674 – A typo in gmarkup.c diff --git a/glib/gmain.c b/glib/gmain.c index 28292ba31..d2d6122f2 100644 --- a/glib/gmain.c +++ b/glib/gmain.c @@ -3320,7 +3320,7 @@ g_timeout_set_expiration (GTimeoutSource *timeout_source, if (!session_bus_address) session_bus_address = g_getenv ("HOSTNAME"); if (session_bus_address) - timer_perturb = g_str_hash (session_bus_address); + timer_perturb = ABS (g_str_hash (session_bus_address)); else timer_perturb = 0; }