mirror of
https://github.com/Comfy-Org/ComfyUI-Manager.git
synced 2025-12-18 02:43:00 +08:00
Encapsulate Python executable and args in double quotes (#621)
If a paths contain spaces, the execv needs quotation marks to not implicitly split those paths into multiple arguments Co-authored-by: DukeSniper <>
This commit is contained in:
parent
2c949dcb4e
commit
853f85987e
@ -1081,6 +1081,9 @@ def restart(self):
|
||||
exit(0)
|
||||
|
||||
print(f"\nRestarting... [Legacy Mode]\n\n")
|
||||
if sys.platform.startswith('win32'):
|
||||
return os.execv(sys.executable, ['"' + sys.executable + '"', '"' + sys.argv[0] + '"'] + sys.argv[1:])
|
||||
else:
|
||||
return os.execv(sys.executable, [sys.executable] + sys.argv)
|
||||
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user