Skip to content

Commit

Permalink
#1527 do create a specific named pipe, generate the path from the use…
Browse files Browse the repository at this point in the history
…rname we shadow as

git-svn-id: https://xpra.org/svn/Xpra/trunk@23621 3bb7dfac-3a0b-4e04-842a-767bc560f471
  • Loading branch information
totaam committed Aug 28, 2019
1 parent aba7e1a commit 12f471b
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/xpra/platform/win32/proxy_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ def exec_command(username, command, env):
log("Popen(%s)=%s", command, proc)
return proc


class ProxyServer(_ProxyServer):

def start_new_session(self, username, uid, gid, new_session_dict=None, displays=()):
Expand All @@ -54,9 +55,11 @@ def start_win32_shadow(self, username, new_session_dict):
#exec_command([whoami])
port = 10000
xpra_command = os.path.join(get_app_dir(), "xpra.exe")
named_pipe = username.replace(" ", "_")
command = [
xpra_command,
"shadow",
"--bind=%s" % named_pipe,
"--bind-tcp=0.0.0.0:%i" % port,
]
from xpra.log import debug_enabled_categories
Expand All @@ -75,4 +78,4 @@ def start_win32_shadow(self, username, new_session_dict):
raise Exception("shadow subprocess failed with exit code %s" % r)
self.child_reaper.add_process(proc, "server-%s" % username, "xpra shadow", True, True)
#exec_command(["C:\\Windows\notepad.exe"])
return proc, "tcp/localhost:%i" % port, "Main"
return proc, "tcp/localhost:%i" % port, "named-pipe://%s" % named_pipe

0 comments on commit 12f471b

Please sign in to comment.