author | zautrix <zautrix> | 2005-04-20 10:43:07 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2005-04-20 10:43:07 (UTC) |
commit | f23afbb9c09b4ee0f00af8f04ee4458181792cd0 (patch) (unidiff) | |
tree | 807bcaf329d257ec2a0c5c6e3a6afc7ab53a6078 /libkcal | |
parent | 03f7f26ad34f50dd86f335c7c5a25a292d642793 (diff) | |
download | kdepimpi-f23afbb9c09b4ee0f00af8f04ee4458181792cd0.zip kdepimpi-f23afbb9c09b4ee0f00af8f04ee4458181792cd0.tar.gz kdepimpi-f23afbb9c09b4ee0f00af8f04ee4458181792cd0.tar.bz2 |
fixes
-rw-r--r-- | libkcal/icalformatimpl.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/libkcal/icalformatimpl.cpp b/libkcal/icalformatimpl.cpp index fe7413f..2405682 100644 --- a/libkcal/icalformatimpl.cpp +++ b/libkcal/icalformatimpl.cpp | |||
@@ -694,14 +694,16 @@ icalcomponent *ICalFormatImpl::writeAlarm(Alarm *alarm) | |||
694 | icalcomponent_add_property(a,icalproperty_new_attach(attach)); | 694 | icalcomponent_add_property(a,icalproperty_new_attach(attach)); |
695 | if (!alarm->programArguments().isEmpty()) { | 695 | if (!alarm->programArguments().isEmpty()) { |
696 | icalcomponent_add_property(a,icalproperty_new_description(alarm->programArguments().utf8())); | 696 | icalcomponent_add_property(a,icalproperty_new_description(alarm->programArguments().utf8())); |
697 | } | 697 | } |
698 | icalattach_unref( attach ); | ||
698 | break; | 699 | break; |
699 | case Alarm::Audio: | 700 | case Alarm::Audio: |
700 | action = ICAL_ACTION_AUDIO; | 701 | action = ICAL_ACTION_AUDIO; |
701 | if (!alarm->audioFile().isEmpty()) { | 702 | if (!alarm->audioFile().isEmpty()) { |
702 | attach = icalattach_new_from_url(QFile::encodeName( alarm->audioFile() ).data()); | 703 | attach = icalattach_new_from_url(QFile::encodeName( alarm->audioFile() ).data()); |
703 | icalcomponent_add_property(a,icalproperty_new_attach(attach)); | 704 | icalcomponent_add_property(a,icalproperty_new_attach(attach)); |
705 | icalattach_unref( attach ); | ||
704 | } | 706 | } |
705 | break; | 707 | break; |
706 | case Alarm::Email: { | 708 | case Alarm::Email: { |
707 | action = ICAL_ACTION_EMAIL; | 709 | action = ICAL_ACTION_EMAIL; |
@@ -718,9 +720,10 @@ icalcomponent *ICalFormatImpl::writeAlarm(Alarm *alarm) | |||
718 | QStringList attachments = alarm->mailAttachments(); | 720 | QStringList attachments = alarm->mailAttachments(); |
719 | if (attachments.count() > 0) { | 721 | if (attachments.count() > 0) { |
720 | for (QStringList::Iterator at = attachments.begin(); at != attachments.end(); ++at) { | 722 | for (QStringList::Iterator at = attachments.begin(); at != attachments.end(); ++at) { |
721 | attach = icalattach_new_from_url(QFile::encodeName( *at ).data()); | 723 | attach = icalattach_new_from_url(QFile::encodeName( *at ).data()); |
722 | icalcomponent_add_property(a,icalproperty_new_attach(attach)); | 724 | icalcomponent_add_property(a,icalproperty_new_attach(attach)); |
725 | icalattach_unref( attach ); | ||
723 | } | 726 | } |
724 | } | 727 | } |
725 | break; | 728 | break; |
726 | } | 729 | } |