diff options
author | Milan Crha <mcrha@redhat.com> | 2013-11-15 16:06:57 +0800 |
---|---|---|
committer | Milan Crha <mcrha@redhat.com> | 2013-11-15 16:06:57 +0800 |
commit | 570c6374806d0f1ec59cf7a72543efe6b5b637be (patch) | |
tree | c5390b1fcb73f30c28bf37168add9bf1dc622b42 /calendar/gui/itip-utils.c | |
parent | 1be51f232560f864ba8795a38e55d472b5b0e2b3 (diff) | |
download | gsoc2013-evolution-570c6374806d0f1ec59cf7a72543efe6b5b637be.tar gsoc2013-evolution-570c6374806d0f1ec59cf7a72543efe6b5b637be.tar.gz gsoc2013-evolution-570c6374806d0f1ec59cf7a72543efe6b5b637be.tar.bz2 gsoc2013-evolution-570c6374806d0f1ec59cf7a72543efe6b5b637be.tar.lz gsoc2013-evolution-570c6374806d0f1ec59cf7a72543efe6b5b637be.tar.xz gsoc2013-evolution-570c6374806d0f1ec59cf7a72543efe6b5b637be.tar.zst gsoc2013-evolution-570c6374806d0f1ec59cf7a72543efe6b5b637be.zip |
Fix/mute issues found by Coverity scan
This makes the code free of Coverity scan issues.
It is sometimes quite pedantic and expects/suggests some
coding habits, thus certain changes may look weird, but for a good
thing, I hope. The code is also tagged with Coverity scan
suppressions, to keep the code as is and hide the warning too.
Also note that Coverity treats g_return_if_fail(), g_assert() and
similar macros as unreliable, and it's true these can be disabled
during the compile time, thus it brings in other set of 'weird'
changes.
Diffstat (limited to 'calendar/gui/itip-utils.c')
-rw-r--r-- | calendar/gui/itip-utils.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/calendar/gui/itip-utils.c b/calendar/gui/itip-utils.c index d8cc740a3b..1a48a29ee4 100644 --- a/calendar/gui/itip-utils.c +++ b/calendar/gui/itip-utils.c @@ -634,6 +634,7 @@ comp_from (ECalComponentItipMethod method, return sender; if (!e_cal_component_has_attendees (comp)) return NULL; + /* coverity[fallthrough] */ case E_CAL_COMPONENT_METHOD_CANCEL: @@ -1844,7 +1845,6 @@ reply_to_calendar_comp (ESourceRegistry *registry, ECalComponent *comp = NULL; icalcomponent *top_level = NULL; icaltimezone *default_zone; - GSList *users = NULL; gchar *subject = NULL; gchar *ical_string = NULL; gboolean retval = FALSE; @@ -1865,7 +1865,7 @@ reply_to_calendar_comp (ESourceRegistry *registry, /* Recipients */ destinations = comp_to_list ( - registry, method, comp, users, reply_all, NULL); + registry, method, comp, NULL, reply_all, NULL); /* Subject information */ subject = comp_subject (registry, method, comp); @@ -2003,11 +2003,6 @@ reply_to_calendar_comp (ESourceRegistry *registry, if (top_level != NULL) icalcomponent_free (top_level); - if (users) { - g_slist_foreach (users, (GFunc) g_free, NULL); - g_slist_free (users); - } - g_free (subject); g_free (ical_string); return retval; |