equal
deleted
inserted
replaced
571 # this may mean the rest of the name is |
571 # this may mean the rest of the name is |
572 # unable to be parsed, and may show errors |
572 # unable to be parsed, and may show errors |
573 # so this is left for debugging. New types |
573 # so this is left for debugging. New types |
574 # encountered need to be parsed properly. |
574 # encountered need to be parsed properly. |
575 # |
575 # |
576 #print "UNKNOWN TYPE = " + str(info[0]) |
576 # print "UNKNOWN TYPE = " + str(info[0]) |
577 #raise BadTypeInNameException |
577 # raise BadTypeInNameException |
578 pass |
578 pass |
579 |
579 |
580 if rec is not None: |
580 if rec is not None: |
581 self.answers.append(rec) |
581 self.answers.append(rec) |
582 |
582 |
1537 self.send(out, addr, port) |
1537 self.send(out, addr, port) |
1538 |
1538 |
1539 def send(self, out, addr=_MDNS_ADDR, port=_MDNS_PORT): |
1539 def send(self, out, addr=_MDNS_ADDR, port=_MDNS_PORT): |
1540 """Sends an outgoing packet.""" |
1540 """Sends an outgoing packet.""" |
1541 # This is a quick test to see if we can parse the packets we generate |
1541 # This is a quick test to see if we can parse the packets we generate |
1542 #temp = DNSIncoming(out.packet()) |
1542 # temp = DNSIncoming(out.packet()) |
1543 try: |
1543 try: |
1544 bytes_sent = self.socket.sendto(out.packet(), 0, (addr, port)) |
1544 bytes_sent = self.socket.sendto(out.packet(), 0, (addr, port)) |
1545 except Exception: |
1545 except Exception: |
1546 # Ignore this, it may be a temporary loss of network connection |
1546 # Ignore this, it may be a temporary loss of network connection |
1547 pass |
1547 pass |