Commit c7c1f699 authored by Guido van Rossum's avatar Guido van Rossum

Fix the Windows version of the ro_svr code.

parent d99cf84b
......@@ -64,10 +64,10 @@ if os.name == "nt":
if script.endswith('.pyc'):
script = script[:-1]
if ro_svr:
args = (sys.executable, script, "-r")
prefix = (sys.executable, script, "-r")
else:
args = (sys.executable, script)
args += (str(port), storage_name) + args
prefix = (sys.executable, script)
args = prefix + (str(port), storage_name) + args
d = os.environ.copy()
d['PYTHONPATH'] = os.pathsep.join(sys.path)
pid = os.spawnve(os.P_NOWAIT, sys.executable, args, d)
......
......@@ -55,7 +55,7 @@ def main(args):
if args[0] == "-r":
ro_svr = 1
del args[0]
port, storage_name, rawargs = args
port, storage_name, rawargs = args[0], args[1], args[2:]
klass = load_storage_class(storage_name)
args = []
for arg in rawargs:
......@@ -66,7 +66,7 @@ def main(args):
zeo_port = int(port)
test_port = zeo_port + 1
t = ZEOTestServer(('', test_port), storage)
addr = [('', zeo_port)]
addr = ('', zeo_port)
serv = ZEO.StorageServer.StorageServer(addr, {'1': storage}, ro_svr)
import zLOG
label = "winserver:%d" % os.getpid()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment