equal
deleted
inserted
replaced
229 def _addService(self, _type, name): |
229 def _addService(self, _type, name): |
230 ''' |
230 ''' |
231 called when a service with the desired type is discovered. |
231 called when a service with the desired type is discovered. |
232 ''' |
232 ''' |
233 info = self.ZeroConfInstance.get_service_info(_type, name) |
233 info = self.ZeroConfInstance.get_service_info(_type, name) |
|
234 if info is None: |
|
235 return |
234 svcname = name.split(".")[0] |
236 svcname = name.split(".")[0] |
235 typename = info.properties.get("protocol", None) |
237 typename = info.properties.get("protocol", None) |
236 ip = str(socket.inet_ntoa(info.address)) |
238 ip = str(socket.inet_ntoa(info.address)) |
237 port = info.port |
239 port = info.port |
238 |
240 |