add ipv6 support

This commit is contained in:
Fedor Kovalev 2014-09-03 13:36:11 +04:00
parent 3a8683e89d
commit 9097b0d7ba
1 changed files with 1 additions and 2 deletions

View File

@ -100,8 +100,7 @@ class GraphiteSink(Sink):
for host in self._hosts:
# flush stats to graphite
try:
sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
sock.connect(host)
sock = socket.create_connection(host)
sock.sendall(buf.getvalue())
sock.close()
except Exception, ex: