diff options
author | bbryant <bbryant@f38db490-d61c-443f-a65b-d21fe96a405b> | 2010-09-09 18:51:52 +0000 |
---|---|---|
committer | bbryant <bbryant@f38db490-d61c-443f-a65b-d21fe96a405b> | 2010-09-09 18:51:52 +0000 |
commit | 722eb3c4c3cfa1c0cee915c949c5f95199ee24dd (patch) | |
tree | 25683963c5e51bdedd6211cd0ea92a85639505c3 /res/res_calendar_caldav.c | |
parent | 815b5b09da5e555add7bba3d8fca588e7611248a (diff) |
Merged revisions 285710 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.6.2
........
r285710 | bbryant | 2010-09-09 14:50:13 -0400 (Thu, 09 Sep 2010) | 8 lines
Fixes an issue with dialplan pattern matching where the specificity for pattern ranges and pattern special characters was inconsistent.
(closes issue #16903)
Reported by: Nick_Lewis
Patches:
pbx.c-specificity.patch uploaded by Nick Lewis (license 657)
Tested by: Nick_Lewis
........
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.8@285711 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'res/res_calendar_caldav.c')
-rw-r--r-- | res/res_calendar_caldav.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/res/res_calendar_caldav.c b/res/res_calendar_caldav.c index 664f25b87..e0d8c483e 100644 --- a/res/res_calendar_caldav.c +++ b/res/res_calendar_caldav.c @@ -216,6 +216,12 @@ static int caldav_write_event(struct ast_calendar_event *event) if (!ast_strlen_zero(event->location)) { icalcomponent_add_property(icalevent, icalproperty_new_location(event->location)); } + if (!ast_strlen_zero(event->categories)) { + icalcomponent_add_property(icalevent, icalproperty_new_categories(event->categories)); + } + if (event->priority > 0) { + icalcomponent_add_property(icalevent, icalproperty_new_priority(event->priority)); + } switch (event->busy_state) { case AST_CALENDAR_BS_BUSY: @@ -365,6 +371,14 @@ static void caldav_add_event(icalcomponent *comp, struct icaltime_span *span, vo ast_string_field_set(event, location, icalproperty_get_value_as_string(prop)); } + if ((prop = icalcomponent_get_first_property(comp, ICAL_CATEGORIES_PROPERTY))) { + ast_string_field_set(event, categories, icalproperty_get_value_as_string(prop)); + } + + if ((prop = icalcomponent_get_first_property(comp, ICAL_PRIORITY_PROPERTY))) { + event->priority = icalvalue_get_integer(icalproperty_get_value(prop)); + } + if ((prop = icalcomponent_get_first_property(comp, ICAL_UID_PROPERTY))) { ast_string_field_set(event, uid, icalproperty_get_value_as_string(prop)); } else { |