Skip to content

Commit

Permalink
#1123 remove anything pointing to dbus from the current env (so we on…
Browse files Browse the repository at this point in the history
…ly detect a dbus instance started by pam, and override everything else)

git-svn-id: https://xpra.org/svn/Xpra/trunk@22662 3bb7dfac-3a0b-4e04-842a-767bc560f471
  • Loading branch information
totaam committed May 8, 2019
1 parent c2bae64 commit 71f282e
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/xpra/scripts/server.py
Original file line number Diff line number Diff line change
Expand Up @@ -548,6 +548,13 @@ def do_run_server(error_cb, opts, mode, xpra_file, extra_args, desktop_display=N
if opts.encoding=="help" or "help" in opts.encodings:
return show_encoding_help(opts)

#remove anything pointing to dbus from the current env
#(so we only detect a dbus instance started by pam,
# and override everything else)
for k in os.environ.keys():
if k.startswith("DBUS_"):
del os.environ[k]

starting = mode == "start"
starting_desktop = mode == "start-desktop"
upgrading = mode == "upgrade"
Expand Down Expand Up @@ -950,7 +957,6 @@ def noerr(fn, *args):
dbus_pid, dbus_env = start_dbus(opts.dbus_launch)
if dbus_env:
os.environ.update(dbus_env)
os.environ.update(protected_env)

display = None
if not proxying:
Expand Down

0 comments on commit 71f282e

Please sign in to comment.