dir: Add some precondition checks to repo_pull()

This commit is contained in:
Phaedrus Leeds
2022-02-20 18:37:12 -06:00
committed by Phaedrus Leeds
parent 11158c2481
commit af04ea669a

View File

@@ -5286,6 +5286,9 @@ repo_pull (OstreeRepo *self,
const char *refs_to_fetch[2];
g_autofree char *sideload_url = NULL;
g_return_val_if_fail (ref_to_fetch != NULL, FALSE);
g_return_val_if_fail (rev_to_fetch != NULL, FALSE);
/* The ostree fetcher asserts if error is NULL */
if (error == NULL)
error = &dummy_error;