Techcable / pircbotx

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

DCC doesn't parse plain IPv6 addresses #206

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
From https://groups.google.com/forum/#!topic/pircbotx/I1d1-k8lj-A

14:34:05.711 [main] INFO  InputParser - :USERNAME!~HOSTNAME PRIVMSG otest : DCC 
SEND file.txt x001:41d0xxxipv6xxx 33030 6069
14:34:05.712 [main] ERROR PircBotX - Exception encountered when parsing line
java.lang.NumberFormatException: For input string: "001:41d0:"
at 
java.lang.NumberFormatException.forInputString(NumberFormatException.java:65) 
~[na:1.7.0_65]
at java.lang.Integer.parseInt(Integer.java:492) ~[na:1.7.0_65]
at java.math.BigInteger.<init>(BigInteger.java:347) ~[na:1.7.0_65]
at java.math.BigInteger.<init>(BigInteger.java:476) ~[na:1.7.0_65]
at org.pircbotx.dcc.DccHandler.integerToAddress(DccHandler.java:523) 
~[pircbotx-2.1.jar:na]
at org.pircbotx.dcc.DccHandler.processDcc(DccHandler.java:80) 
~[pircbotx-2.1.jar:na]
at org.pircbotx.InputParser.processCommand(InputParser.java:483) 
~[pircbotx-2.1.jar:na]
at org.pircbotx.InputParser.handleLine(InputParser.java:353) 
~[pircbotx-2.1.jar:na]
at org.pircbotx.PircBotX.startLineProcessing(PircBotX.java:283) 
[pircbotx-2.1.jar:na]
at org.pircbotx.PircBotX.connect(PircBotX.java:244) [pircbotx-2.1.jar:na]
at org.pircbotx.PircBotX.startBot(PircBotX.java:151) [pircbotx-2.1.jar:na]
at ircbot.Bot.start(Bot.java:114) [bin/:na]
at ircbot.Bot.<init>(Bot.java:63) [bin/:na]
at ircbot.Bot.main(Bot.java:72) [bin/:na]

Code assumes address is an IPv6 address converted to a giant integer. 

Original issue reported on code.google.com by Lord.Qua...@gmail.com on 10 Oct 2014 at 3:57

GoogleCodeExporter commented 9 years ago
Fixed in Revision 4ac3b8005aab

Original comment by Lord.Qua...@gmail.com on 30 Oct 2014 at 7:45