]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
suri-graphite: fix port option
authorEric Leblond <eric@regit.org>
Sun, 17 May 2015 16:57:48 +0000 (18:57 +0200)
committerVictor Julien <victor@inliniac.net>
Fri, 22 May 2015 13:50:43 +0000 (15:50 +0200)
If port is specified on command line we need to convert it as an
integer before using it as argument to connect.

contrib/suri-graphite

index 7a71ecf2dd5f87dc7d57f4694806dc01f2e25b44..83422e89d58f677a9149c26adbfee6556c0a425e 100755 (executable)
@@ -35,7 +35,7 @@ sc = suricatasc.SuricataSC(args.socket)
 sc.connect()
 
 sck = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
-sck.connect((args.host, args.port))
+sck.connect((args.host, int(args.port)))
 
 while 1:
     res = sc.send_command("dump-counters")