[gnome-software/wip/temp/ubuntu-xenial-rebased-corrected: 291/331] Disable Snappy plugin if GNOME_SOFTWARE_SNAPPY isn't set
- From: William Hua <williamhua src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-software/wip/temp/ubuntu-xenial-rebased-corrected: 291/331] Disable Snappy plugin if GNOME_SOFTWARE_SNAPPY isn't set
- Date: Wed, 4 May 2016 14:22:59 +0000 (UTC)
commit 8f754300c019b27691d611ad304eb8b5612b9379
Author: William Hua <william hua canonical com>
Date: Mon Apr 25 14:05:04 2016 +0200
Disable Snappy plugin if GNOME_SOFTWARE_SNAPPY isn't set
src/plugins/gs-plugin-snappy.c | 5 +++++
1 files changed, 5 insertions(+), 0 deletions(-)
---
diff --git a/src/plugins/gs-plugin-snappy.c b/src/plugins/gs-plugin-snappy.c
index 76035f8..72a3a31 100644
--- a/src/plugins/gs-plugin-snappy.c
+++ b/src/plugins/gs-plugin-snappy.c
@@ -46,6 +46,11 @@ gs_plugin_initialize (GsPlugin *plugin)
/* create private area */
plugin->priv = GS_PLUGIN_GET_PRIVATE (GsPluginPrivate);
+ if (g_getenv ("GNOME_SOFTWARE_SNAPPY") == NULL) {
+ gs_plugin_set_enabled (plugin, FALSE);
+ return;
+ }
+
if (!g_file_test (SNAPD_SOCKET, G_FILE_TEST_EXISTS)) {
g_debug ("disabling '%s' as no %s available",
plugin->name, SNAPD_SOCKET);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]