Merge lp:~renatofilho/qtorganizer5-eds/optimize-id-parse into lp:qtorganizer5-eds

Proposed by Renato Araujo Oliveira Filho
Status: Merged
Approved by: Bill Filler
Approved revision: 49
Merged at revision: 49
Proposed branch: lp:~renatofilho/qtorganizer5-eds/optimize-id-parse
Merge into: lp:qtorganizer5-eds
Diff against target: 24 lines (+8/-6)
1 file modified
qorganizer/qorganizer-eds-viewwatcher.cpp (+8/-6)
To merge this branch: bzr merge lp:~renatofilho/qtorganizer5-eds/optimize-id-parse
Reviewer Review Type Date Requested Status
Bill Filler (community) Approve
PS Jenkins bot continuous-integration Approve
Review via email: mp+215470@code.launchpad.net

Commit message

Optimize eventid parse, and avoid memory leak.

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
Revision history for this message
Bill Filler (bfiller) wrote :

Did you perform an exploratory manual test run of the code change and any related functionality on device or emulator?
yes

Did you successfully run all tests found in your component's Test Plan (https://wiki.ubuntu.com/Process/Merges/TestPlan/<package-name>) on device or emulator?
yes

Did CI run pass? If not, please explain why.
yes

Have you checked that submitter has accurately filled out the submitter checklist and has taken no shortcut?
yes

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'qorganizer/qorganizer-eds-viewwatcher.cpp'
--- qorganizer/qorganizer-eds-viewwatcher.cpp 2014-02-25 17:00:58 +0000
+++ qorganizer/qorganizer-eds-viewwatcher.cpp 2014-04-11 17:51:23 +0000
@@ -138,12 +138,14 @@
138138
139 for (GSList *l = objects; l; l = l->next) {139 for (GSList *l = objects; l; l = l->next) {
140 const gchar *uid = 0;140 const gchar *uid = 0;
141 ECalComponent *comp;141 icalcomponent *icalcomp = static_cast<icalcomponent*>(l->data);
142142 icalproperty *prop = icalcomponent_get_first_property(icalcomp, ICAL_UID_PROPERTY);
143 icalcomponent *clone = icalcomponent_new_clone(static_cast<icalcomponent*>(l->data));143 if (prop) {
144 comp = e_cal_component_new_from_icalcomponent(clone);144 uid = icalproperty_get_uid(prop);
145145 } else {
146 e_cal_component_get_uid(comp, &uid);146 qWarning() << "Fail to parse component ID";
147 }
148
147 QOrganizerEDSEngineId *itemId = new QOrganizerEDSEngineId(m_collectionId,149 QOrganizerEDSEngineId *itemId = new QOrganizerEDSEngineId(m_collectionId,
148 QString::fromUtf8(uid));150 QString::fromUtf8(uid));
149 result << QOrganizerItemId(itemId);151 result << QOrganizerItemId(itemId);

Subscribers

People subscribed via source and target branches