]> code.citadel.org Git - citadel.git/blobdiff - webcit/calendar.c
ICAL: some work on adding ical items into templates
[citadel.git] / webcit / calendar.c
index 58b00a84ef383cf208196bdf59a438ba2dc0fd4d..b919f001a5c6595de4c7de430e18ac206bd4956f 100644 (file)
@@ -5,17 +5,11 @@
  *
  * This program is open source software.  You can redistribute it and/or
  * modify it under the terms of the GNU General Public License, version 3.
- * 
- * 
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- *
- * 
- * 
- * 
  */
 
 #include "webcit.h"
@@ -376,9 +370,9 @@ void handle_rsvp(void)
        if (buf[0] == '2') {
                wc_printf("<img src=\"static/webcit_icons/calendar.png\"><span>");
                if (!strcasecmp(bstr("sc"), "update")) {
-                       /* Translators: RSVP aka Répondez s'il-vous-plaît Is the term 
-                          that the recipient of an ical-invitation should please 
-                          answer this request. */                                        
+                       /// Translators: RSVP aka Répondez s'il-vous-plaît Is the term 
+                       /// that the recipient of an ical-invitation should please 
+                       /// answer this request.
                        wc_printf(_("Your calendar has been updated to reflect this RSVP."));
                } else if (!strcasecmp(bstr("sc"), "ignore")) {
                        wc_printf(_("You have chosen to ignore this RSVP. "
@@ -504,6 +498,9 @@ void display_individual_cal(icalcomponent *event, long msgnum, char *from, int u
        if (!icaltime_is_null_time(dtend)) {            /* Need duration for recurrences */
                dur = icaltime_subtract(dtend, dtstart);
        }
+       else {
+               dur = icaltime_subtract(dtstart, dtstart);
+       }
 
        /*
         * Just let libical iterate the recurrence, and keep looping back to the top of this function,