mirror of https://github.com/zulip/zulip.git
run-dev: Clarify magic number for errno.EADDRINUSE.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
parent
fc0f73c1db
commit
13d92acdb3
|
@ -1,6 +1,7 @@
|
||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
import argparse
|
import argparse
|
||||||
import asyncio
|
import asyncio
|
||||||
|
import errno
|
||||||
import os
|
import os
|
||||||
import pwd
|
import pwd
|
||||||
import signal
|
import signal
|
||||||
|
@ -359,7 +360,7 @@ async def serve() -> None:
|
||||||
try:
|
try:
|
||||||
app.listen(proxy_port, address=options.interface)
|
app.listen(proxy_port, address=options.interface)
|
||||||
except OSError as e:
|
except OSError as e:
|
||||||
if e.errno == 98:
|
if e.errno == errno.EADDRINUSE:
|
||||||
print("\n\nERROR: You probably have another server running!!!\n\n")
|
print("\n\nERROR: You probably have another server running!!!\n\n")
|
||||||
raise
|
raise
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue