[gdm] Check envrioment WINDOWPATH before setting it.



commit 1d2ece98b97adff869af3eaf65d44202ed7a7af9
Author: Halton Huo <halton huo sun com>
Date:   Thu May 13 14:48:25 2010 +0800

    Check envrioment WINDOWPATH before setting it.
    
    Fixes https://bugzilla.gnome.org/show_bug.cgi?id=618510

 daemon/gdm-session-direct.c |    8 +++++---
 1 files changed, 5 insertions(+), 3 deletions(-)
---
diff --git a/daemon/gdm-session-direct.c b/daemon/gdm-session-direct.c
index 9aa47fc..7d5b560 100644
--- a/daemon/gdm-session-direct.c
+++ b/daemon/gdm-session-direct.c
@@ -2063,9 +2063,11 @@ setup_session_environment (GdmSessionDirect *session)
                                                              session->priv->user_x11_authority_file);
         }
 
-        gdm_session_direct_set_environment_variable (session,
-                                                     "WINDOWPATH",
-                                                     g_getenv ("WINDOWPATH"));
+        if (g_getenv ("WINDOWPATH") != NULL) {
+                gdm_session_direct_set_environment_variable (session,
+                                                             "WINDOWPATH",
+                                                             g_getenv ("WINDOWPATH"));
+        }
 
 
         /* FIXME: We do this here and in the session worker.  We should consolidate



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]