[gnome-builder/gnome-builder-3-28] flatpak: check for env before accessing it
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder/gnome-builder-3-28] flatpak: check for env before accessing it
- Date: Wed, 4 Jul 2018 21:50:03 +0000 (UTC)
commit 00ef6196e8f6152b6fe2d357c44ef6f1ae2727ba
Author: Christian Hergert <chergert redhat com>
Date: Wed Jul 4 23:48:54 2018 +0200
flatpak: check for env before accessing it
src/plugins/flatpak/gbp-flatpak-manifest.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
---
diff --git a/src/plugins/flatpak/gbp-flatpak-manifest.c b/src/plugins/flatpak/gbp-flatpak-manifest.c
index 3608e6ab6..dcd427ade 100644
--- a/src/plugins/flatpak/gbp-flatpak-manifest.c
+++ b/src/plugins/flatpak/gbp-flatpak-manifest.c
@@ -222,7 +222,8 @@ discover_environ (GbpFlatpakManifest *self,
env = ide_configuration_get_environment (IDE_CONFIGURATION (self));
- if ((obj = json_object_get_object_member (build_options, "env")))
+ if (json_object_has_member (build_options, "env") &&
+ (obj = json_object_get_object_member (build_options, "env")))
{
JsonObjectIter iter;
const gchar *key;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]