aboutsummaryrefslogtreecommitdiffstats
path: root/src/dmon.c
diff options
context:
space:
mode:
authorFrederic Culot <calcurse@culot.org>2009-08-01 20:29:49 +0000
committerFrederic Culot <calcurse@culot.org>2009-08-01 20:29:49 +0000
commitf1403e99bbcf2c3fe77b9f41150d27e60a1a7a1a (patch)
tree8ad8442a1e79b350f068c280e223e4c5397fafd2 /src/dmon.c
parent0cbeb9c38bffd4052190b8450ae336f0641a84d2 (diff)
downloadcalcurse-f1403e99bbcf2c3fe77b9f41150d27e60a1a7a1a.tar.gz
calcurse-f1403e99bbcf2c3fe77b9f41150d27e60a1a7a1a.zip
Improved how the daemon checks for appointments to remind.
Diffstat (limited to 'src/dmon.c')
-rw-r--r--src/dmon.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/dmon.c b/src/dmon.c
index 2f28d4c..9913361 100644
--- a/src/dmon.c
+++ b/src/dmon.c
@@ -1,4 +1,4 @@
-/* $calcurse: dmon.c,v 1.10 2009/08/01 17:53:11 culot Exp $ */
+/* $calcurse: dmon.c,v 1.11 2009/08/01 20:29:49 culot Exp $ */
/*
* Calcurse - text-based organizer
@@ -190,8 +190,9 @@ dmon_start (int parent_exit_status)
if (!notify_get_next_bkgd ())
DMON_ABRT (_("error loading next appointment\n"));
+
left = notify_time_left ();
- if (left < nbar.cntdwn)
+ if (left > 0 && left < nbar.cntdwn && notify_needs_reminder ())
{
DMON_LOG (_("launching notification at %s for: \"%s\"\n"),
nowstr (), notify_app_txt ());