fetch_summary_with_options: drop unnecessary "goto out" use

This commit is contained in:
Alexander Larsson 2020-09-10 11:03:14 +02:00
parent 1f1ef4c989
commit f74bc8dd3d
1 changed files with 7 additions and 11 deletions

View File

@ -6200,7 +6200,6 @@ ostree_repo_remote_fetch_summary_with_options (OstreeRepo *self,
g_autoptr(GBytes) signatures = NULL; g_autoptr(GBytes) signatures = NULL;
gboolean gpg_verify_summary; gboolean gpg_verify_summary;
g_autoptr(GPtrArray) signapi_summary_verifiers = NULL; g_autoptr(GPtrArray) signapi_summary_verifiers = NULL;
gboolean ret = FALSE;
gboolean summary_is_from_cache; gboolean summary_is_from_cache;
g_return_val_if_fail (OSTREE_REPO (self), FALSE); g_return_val_if_fail (OSTREE_REPO (self), FALSE);
@ -6208,7 +6207,7 @@ ostree_repo_remote_fetch_summary_with_options (OstreeRepo *self,
if (!ostree_repo_get_remote_option (self, name, "metalink", NULL, if (!ostree_repo_get_remote_option (self, name, "metalink", NULL,
&metalink_url_string, error)) &metalink_url_string, error))
goto out; return FALSE;
if (!repo_remote_fetch_summary (self, if (!repo_remote_fetch_summary (self,
name, name,
@ -6219,21 +6218,21 @@ ostree_repo_remote_fetch_summary_with_options (OstreeRepo *self,
&summary_is_from_cache, &summary_is_from_cache,
cancellable, cancellable,
error)) error))
goto out; return FALSE;
if (!ostree_repo_remote_get_gpg_verify_summary (self, name, &gpg_verify_summary, error)) if (!ostree_repo_remote_get_gpg_verify_summary (self, name, &gpg_verify_summary, error))
goto out; return FALSE;
if (!_signapi_init_for_remote (self, name, NULL, if (!_signapi_init_for_remote (self, name, NULL,
&signapi_summary_verifiers, &signapi_summary_verifiers,
error)) error))
goto out; return FALSE;
if (!_ostree_repo_verify_summary (self, name, if (!_ostree_repo_verify_summary (self, name,
gpg_verify_summary, signapi_summary_verifiers, gpg_verify_summary, signapi_summary_verifiers,
summary, signatures, summary, signatures,
cancellable, error)) cancellable, error))
goto out; return FALSE;
if (!summary_is_from_cache && summary && signatures) if (!summary_is_from_cache && summary && signatures)
{ {
@ -6251,7 +6250,7 @@ ostree_repo_remote_fetch_summary_with_options (OstreeRepo *self,
else else
{ {
g_propagate_error (error, g_steal_pointer (&temp_error)); g_propagate_error (error, g_steal_pointer (&temp_error));
goto out; return FALSE;
} }
} }
} }
@ -6262,10 +6261,7 @@ ostree_repo_remote_fetch_summary_with_options (OstreeRepo *self,
if (out_signatures != NULL) if (out_signatures != NULL)
*out_signatures = g_steal_pointer (&signatures); *out_signatures = g_steal_pointer (&signatures);
ret = TRUE; return TRUE;
out:
return ret;
} }
#else /* HAVE_LIBCURL_OR_LIBSOUP */ #else /* HAVE_LIBCURL_OR_LIBSOUP */