summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon McVittie <smcv@collabora.com>2018-07-07 12:35:10 +0100
committerAtomic Bot <atomic-devel@projectatomic.io>2018-07-07 16:17:46 +0000
commit7179c12e22f56c0eee41a0d1ac84e3292580dada (patch)
tree545bbe0fe2f476fc00bae11f9443bd19560596f0
parent98fd052695d6e026ff91e87b8778f6fe44b8cbab (diff)
downloadflatpak-7179c12e22f56c0eee41a0d1ac84e3292580dada.tar.gz
Fix error handling while deploying AppStream
Setting an error with second_error->message is going to work poorly when second_error has never been set non-NULL. Related to #1845, although not necessarily the full solution. Signed-off-by: Simon McVittie <smcv@collabora.com> Closes: #1867 Approved by: alexlarsson
-rw-r--r--system-helper/flatpak-system-helper.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/system-helper/flatpak-system-helper.c b/system-helper/flatpak-system-helper.c
index 97ab9b83..78daffff 100644
--- a/system-helper/flatpak-system-helper.c
+++ b/system-helper/flatpak-system-helper.c
@@ -589,7 +589,7 @@ handle_deploy_appstream (FlatpakSystemHelper *object,
{
if (!flatpak_dir_pull (system, state, old_branch, NULL, NULL, NULL, NULL,
FLATPAK_PULL_FLAGS_NONE, OSTREE_REPO_PULL_FLAGS_UNTRUSTED, ostree_progress,
- NULL, NULL))
+ NULL, &second_error))
{
g_prefix_error (&first_error, "Error updating appstream2: ");
g_prefix_error (&second_error, "%s; Error updating appstream: ", first_error->message);