From: <svn...@op...> - 2010-08-31 04:14:13
|
Author: cdfrey Date: Tue Aug 31 06:14:05 2010 New Revision: 6110 URL: http://www.opensync.org/changeset/6110 Log: Cleaned up cleanup code in calendar get_changes function Modified: plugins/google-calendar/src/gcalendar.c Modified: plugins/google-calendar/src/gcalendar.c ============================================================================== --- plugins/google-calendar/src/gcalendar.c Tue Aug 31 06:13:55 2010 (r6109) +++ plugins/google-calendar/src/gcalendar.c Tue Aug 31 06:14:05 2010 (r6110) @@ -516,19 +516,18 @@ exit: - // osync_sink_state_get uses osync_strdup - osync_free(timestamp); osync_context_report_success(ctx); - return; + goto cleanup; + +error: + osync_context_report_error(ctx, OSYNC_ERROR_GENERIC, "%s", msg); cleanup: osync_error_unref(&error); + // osync_sink_state_get uses osync_strdup osync_free(timestamp); -error: - osync_context_report_error(ctx, OSYNC_ERROR_GENERIC, "%s", msg); - } |