From 687e004b1d8aa0f186647b905770033c4af3825a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marek=20Marczykowski-G=C3=B3recki?= Date: Thu, 3 Oct 2013 23:42:51 +0200 Subject: [PATCH] windows: workaround for windows "behavior" regarding parsing exec() arguments --- core-modules/000QubesVm.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/core-modules/000QubesVm.py b/core-modules/000QubesVm.py index 8cbfc0e5..ab6b180c 100644 --- a/core-modules/000QubesVm.py +++ b/core-modules/000QubesVm.py @@ -1437,6 +1437,10 @@ class QubesVm(object): if os.isatty(sys.stderr.fileno()): args += ["-T"] if passio: + if os.name == 'nt': + # see here for the explanation (_exec doc): + # http://msdn.microsoft.com/en-us/library/431x4c1w.aspx + args[0] = '"%"' % args[0] os.execv(system_path["qrexec_client_path"], args) exit(1)