sundaewaffle / sipvicious

Automatically exported from code.google.com/p/sipvicious
0 stars 0 forks source link

-P localport option doesn't work for svwar.py #14

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?

$ ./svwar.py -d accounts.txt -P 5062 localhost
WARNING:TakeASip:could not bind to :5060 - some process might already be 
listening on this port. Listening on port 5061 instead
ERROR:TakeASip:socket error: timed out

The fix is easy.  The OptionParser is properly reading in the -P option, but 
it's not passed in to the TakeASIP() object.  "localport=options.localport" 
needs to be added as an argument when constructing TakeASIP().

Original issue reported on code.google.com by russell....@gmail.com on 16 Dec 2010 at 2:00

GoogleCodeExporter commented 9 years ago
Index: svwar.py
===================================================================
--- svwar.py    (revision 383)
+++ svwar.py    (working copy)
@@ -516,6 +516,7 @@
     sipvicious = TakeASip(
                     host,
                     port=options.port,
+                    localport=options.localport,
                     selecttime=options.selecttime,
                     method=options.method,
                     compact=options.enablecompact,

Original comment by russell....@gmail.com on 16 Dec 2010 at 2:01

GoogleCodeExporter commented 9 years ago
thanks! will commit soon

Original comment by sandrogauc on 16 Dec 2010 at 2:14

GoogleCodeExporter commented 9 years ago
done .. cheers!

Original comment by sandrogauc on 16 Dec 2010 at 2:18