aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorkarl-qdh <karl@qdh.org.uk>2011-02-28 16:45:59 +0000
committerkarl-qdh <karl@qdh.org.uk>2011-02-28 16:45:59 +0000
commitbbd56b119d18a83600c1be706078d3e0d759583d (patch)
tree9dd02179a40fe13559446738045dec625832e6fb /src
parentb79665734363a3644d3eb7b13a110908ac05d3a1 (diff)
downloadayatana-indicator-datetime-bbd56b119d18a83600c1be706078d3e0d759583d.tar.gz
ayatana-indicator-datetime-bbd56b119d18a83600c1be706078d3e0d759583d.tar.bz2
ayatana-indicator-datetime-bbd56b119d18a83600c1be706078d3e0d759583d.zip
Minor change for kenvandine to test sorting
Diffstat (limited to 'src')
-rw-r--r--src/datetime-service.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/src/datetime-service.c b/src/datetime-service.c
index 6303a98..a6e756e 100644
--- a/src/datetime-service.c
+++ b/src/datetime-service.c
@@ -422,8 +422,10 @@ compare_appointment_items (ECalComponent *a,
ECalComponentVType vtype = e_cal_component_get_vtype (a);
- if (vtype != E_CAL_COMPONENT_EVENT && vtype != E_CAL_COMPONENT_TODO) return -1;
-
+ if (vtype != E_CAL_COMPONENT_EVENT && vtype != E_CAL_COMPONENT_TODO) {
+ g_debug("E-Cal Component is neither an event or a todo");
+ return -1;
+ }
if (vtype == E_CAL_COMPONENT_EVENT)
e_cal_component_get_dtstart (a, &datetime_a);
else
@@ -432,8 +434,11 @@ compare_appointment_items (ECalComponent *a,
t_a = mktime(&tm_a);
vtype = e_cal_component_get_vtype (b);
- if (vtype != E_CAL_COMPONENT_EVENT && vtype != E_CAL_COMPONENT_TODO) return 1;
-
+ if (vtype != E_CAL_COMPONENT_EVENT && vtype != E_CAL_COMPONENT_TODO) {
+ e_cal_component_free_datetime (&datetime_a);
+ g_debug("E-Cal Component is neither an event or a todo");
+ return -1;
+ }
if (vtype == E_CAL_COMPONENT_EVENT)
e_cal_component_get_dtstart (b, &datetime_b);
else