ipv6 is complicated
This commit is contained in:
parent
13adeddd1b
commit
6559939fc4
1 changed files with 6 additions and 2 deletions
|
@ -149,8 +149,12 @@ def main():
|
|||
os.chdir(base)
|
||||
|
||||
player = get_player(fullscreen=not args.window)
|
||||
|
||||
listen = '::' if ':' in args.peer else '0.0.0.0'
|
||||
|
||||
if ':' in args.peer:
|
||||
listen = '::'
|
||||
ThreadingUDPServer.address_family = socket.AF_INET6
|
||||
else:
|
||||
listen = '0.0.0.0'
|
||||
server = ThreadingUDPServer((listen, args.port), Handler)
|
||||
server.allow_reuse_address = True
|
||||
server.player = Player(peer, player, args.playlist, args.prefix)
|
||||
|
|
Loading…
Reference in a new issue