forked from Mirrors/flatpak-builder
git: Print details of ignored error when mirroring
Rather than dropping the error on the floor entirely. Coverity CID: #208384 Signed-off-by: Philip Withnall <withnall@endlessm.com> Closes: #74 Approved by: alexlarssontingping/wmclass
parent
287be6a7d1
commit
4e4a7c9af5
|
@ -586,12 +586,16 @@ builder_git_mirror_repo (const char *repo_location,
|
|||
|
||||
if (alternates)
|
||||
{
|
||||
g_autoptr(GError) local_error = NULL;
|
||||
|
||||
/* Ensure we copy the files from the cache, to be safe if the extra source changes */
|
||||
if (!git (mirror_dir, NULL, 0, error,
|
||||
"repack", "-a", "-d", NULL))
|
||||
return FALSE;
|
||||
|
||||
g_file_delete (alternates, NULL, NULL);
|
||||
if (!g_file_delete (alternates, NULL, &local_error) &&
|
||||
!g_error_matches (local_error, G_IO_ERROR, G_IO_ERROR_NOT_FOUND))
|
||||
g_debug ("Error deleting alternates file: %s", local_error->message);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue