$Log$
+Revision 400.73 2002/12/28 05:44:09 ajc
+* ical_dezonify.c: brought over new version from the Citadel source (again)
+
Revision 400.72 2002/12/28 05:12:45 ajc
* ical_dezonify.c: brought over new version from the Citadel source.
1998-12-03 Nathan Bryant <bryant@cs.usm.maine.edu>
* webserver.c: warning fix
+
int organizer_is_me = 0;
int sequence = 0;
- now = time(NULL);
+ now = time(NULL) % 60; /* mod 60 to force :00 seconds */
strcpy(organizer_string, "");
strcpy(attendee_string, "");
if (strlen(bstr("hour")) > 0) {
t_start.hour = atoi(bstr("hour"));
t_start.minute = atoi(bstr("minute"));
+ t_start.second = 0;
}
else {
t_start.hour = 9;
t_start.minute = 0;
+ t_start.second = 0;
}
- /* t_start = icaltime_from_timet(now, 0); */
}
display_icaltimetype_as_webform(&t_start, "dtstart");
*/
t_end = t_start;
t_end.hour += 1;
+ t_end.second = 0;
t_end = icaltime_normalize(t_end);
/* t_end = icaltime_from_timet(now, 0); */
}
icalcomponent *rcal,
icalproperty *prop) {
- icaltimezone *t;
+ icaltimezone *t = NULL;
icalparameter *param;
const char *tzid;
struct icaltimetype TheTime;
/* Hunt for a TZID parameter in this property. */
param = icalproperty_get_first_parameter(prop, ICAL_TZID_PARAMETER);
- if (param == NULL) return;
/* Get the stringish name of this TZID. */
- tzid = icalparameter_get_tzid(param);
- if (tzid == NULL) return;
+ if (param != NULL) {
+ tzid = icalparameter_get_tzid(param);
- /* Convert it to an icaltimezone type. */
- t = icalcomponent_get_timezone(cal, tzid);
- if (t == NULL) return;
+ /* Convert it to an icaltimezone type. */
+ if (tzid != NULL) {
+ t = icalcomponent_get_timezone(cal, tzid);
+ }
+
+ }
/* Now we know the timezone. Convert to UTC. */
}
/* Do the conversion. */
- icaltimezone_convert_time(&TheTime,
- t,
- icaltimezone_get_utc_timezone()
- );
+ if (t != NULL) {
+ icaltimezone_convert_time(&TheTime,
+ t,
+ icaltimezone_get_utc_timezone()
+ );
+ }
TheTime.is_utc = 1;
icalproperty_remove_parameter_by_kind(prop, ICAL_TZID_PARAMETER);