aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--calendar/calendar.c2
-rw-r--r--calendar/gnome-cal.c4
-rw-r--r--calendar/gui/calendar.c2
-rw-r--r--calendar/gui/gnome-cal.c4
4 files changed, 4 insertions, 8 deletions
diff --git a/calendar/calendar.c b/calendar/calendar.c
index 2a5b532a04..5bfb5ea21c 100644
--- a/calendar/calendar.c
+++ b/calendar/calendar.c
@@ -97,8 +97,10 @@ calendar_add_object (Calendar *cal, iCalObject *obj)
case ICAL_EVENT:
cal->events = g_list_prepend (cal->events, obj);
ical_object_try_alarms (obj);
+#ifdef DEBUGGING_MAIL_ALARM
obj->malarm.trigger = 0;
calendar_notify (0, obj);
+#endif
break;
case ICAL_TODO:
diff --git a/calendar/gnome-cal.c b/calendar/gnome-cal.c
index 534db8bb4c..d44c5e89f3 100644
--- a/calendar/gnome-cal.c
+++ b/calendar/gnome-cal.c
@@ -294,10 +294,6 @@ calendar_notify (time_t time, void *data)
if (pid == 0){
const int top = max_open_files ();
int dev_null, i;
-
- for (i = 0; i < top; i++)
- if (i != p [1])
- close (i);
dev_null = open ("/dev/null", O_RDWR);
dup2 (p [1], 0);
dup2 (dev_null, 1);
diff --git a/calendar/gui/calendar.c b/calendar/gui/calendar.c
index 2a5b532a04..5bfb5ea21c 100644
--- a/calendar/gui/calendar.c
+++ b/calendar/gui/calendar.c
@@ -97,8 +97,10 @@ calendar_add_object (Calendar *cal, iCalObject *obj)
case ICAL_EVENT:
cal->events = g_list_prepend (cal->events, obj);
ical_object_try_alarms (obj);
+#ifdef DEBUGGING_MAIL_ALARM
obj->malarm.trigger = 0;
calendar_notify (0, obj);
+#endif
break;
case ICAL_TODO:
diff --git a/calendar/gui/gnome-cal.c b/calendar/gui/gnome-cal.c
index 534db8bb4c..d44c5e89f3 100644
--- a/calendar/gui/gnome-cal.c
+++ b/calendar/gui/gnome-cal.c
@@ -294,10 +294,6 @@ calendar_notify (time_t time, void *data)
if (pid == 0){
const int top = max_open_files ();
int dev_null, i;
-
- for (i = 0; i < top; i++)
- if (i != p [1])
- close (i);
dev_null = open ("/dev/null", O_RDWR);
dup2 (p [1], 0);
dup2 (dev_null, 1);