Index: multiplexer.fcgi |
diff --git a/multiplexer.fcgi b/multiplexer.fcgi |
index d72b2c18a6d7e04b211354ec3a3e38895f74ed65..34019b821e032080445c0968f2ac4b99a2eaaa57 100755 |
--- a/multiplexer.fcgi |
+++ b/multiplexer.fcgi |
@@ -21,10 +21,12 @@ from flup.server.fcgi import WSGIServer |
from sitescripts.web import multiplex |
-bindAddress = None |
-if 'FCGI_BIND_ADDRESS' in os.environ: |
- match = re.match(r'^(.*?):(\d+)$', os.environ['FCGI_BIND_ADDRESS']) |
- bindAddress = (match.group(1), int(match.group(2))) |
+bindAddress = os.environ.get('FCGI_BIND_ADDRESS', None) |
Sebastian Noack
2015/04/01 07:43:27
Nit: .get() defaults to None anyway. So there is n
mathias
2015/04/01 08:03:11
Done.
|
+if bindAddress: |
+ match = re.match(r'^(.*?):(\d+)$', bindAddress) |
Sebastian Noack
2015/04/01 07:43:27
Didn't we agree to don't use re.match() anymore in
Sebastian Noack
2015/04/01 08:01:34
What's about this?
mathias
2015/04/01 08:03:11
Frankly I have no idea what you mean by that.
What
Sebastian Noack
2015/04/01 08:11:27
I'm talking about this discussion: http://coderevi
|
+ if match: |
+ bindAddress = (match.group(1), int(match.group(2))) |
+ |
srv = WSGIServer(multiplex, debug=False, bindAddress=bindAddress) |
if __name__ == '__main__': |