Merging upstream version 0.5.0.
[debian/lxdm.git] / debian / patches / 15-path-replace.patch
CommitLineData
6da61772
DB
1#launchpad bug : #524761
2Index: lxdm-0.4.0/src/lxdm.c
3===================================================================
4--- lxdm-0.4.0.orig/src/lxdm.c 2011-07-13 14:00:34.000000000 +0200
5+++ lxdm-0.4.0/src/lxdm.c 2011-07-24 18:00:58.000000000 +0200
6@@ -1472,7 +1472,7 @@
7 path = g_key_file_get_string(config, "base", "path", 0);
8 if( G_UNLIKELY(path) && path[0] ) /* if PATH is specified in config file */
9 replace_env(env, "PATH=", path); /* override current $PATH with config value */
10- else /* don't use the global env, they are bad for user */
11+ else if(!getenv("PATH")) /* if PATH is not set */
12 replace_env(env, "PATH=", "/usr/local/bin:/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/sbin"); /* set proper default */
13 g_free(path);
14 /* optionally override $LANG, $LC_MESSAGES, and $LANGUAGE */