Show More
@@ -46,7 +46,11 b' def getip():' | |||||
46 | def publish(name, desc, path, port): |
|
46 | def publish(name, desc, path, port): | |
47 | global server, localip |
|
47 | global server, localip | |
48 | if not server: |
|
48 | if not server: | |
49 | server = Zeroconf.Zeroconf() |
|
49 | try: | |
|
50 | server = Zeroconf.Zeroconf() | |||
|
51 | except socket.gaierror: | |||
|
52 | # if we have no internet connection, this can happen. | |||
|
53 | return | |||
50 | ip = getip() |
|
54 | ip = getip() | |
51 | localip = socket.inet_aton(ip) |
|
55 | localip = socket.inet_aton(ip) | |
52 |
|
56 |
General Comments 0
You need to be logged in to leave comments.
Login now