Mofsy / jinxbot

Automatically exported from code.google.com/p/jinxbot
1 stars 1 forks source link

BNSharp: ArgumentOutOfRangeException when joining a channel with Starcraft Shareware user in it. #23

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
IF YOU HAVE AN ISSUE WITH BN#, PLEASE ATTACH A WIRESHARK PACKET CAPTURE
(*.cap) THAT DEMONSTRATES THE PROBLEM.  WIRESHARK CAN BE DOWNLOADED FROM
http://www.wireshark.org/.  WITHOUT A WIRESHARK PACKET CAPTURE FOR PROBLEMS
RELATING TO BN#, THE ISSUE WILL BE MARKED AS INVALID.

What steps will reproduce the problem?
1.Set up the 10 minute bot client from the wiki.
2.Join a channel with a Starcraft Shareware user.
3.

What is the expected output? What do you see instead?
System.ArgumentOutOfRangeException
"Index and count must refer to a location within the buffer.\r\nParameter
name: bytes"
   at System.Text.ASCIIEncoding.GetString(Byte[] bytes, Int32 byteIndex,
Int32 byteCount)
   at BNSharp.MBNCSUtil.DataReader.ReadTerminatedString(Char Terminator,
Encoding enc)
   at BNSharp.BattleNet.Stats.StarcraftStats..ctor(Byte[] stats)
   at BNSharp.BattleNet.Stats.UserStats.Parse(String userName, Byte[]
statsData)
   at BNSharp.Net.BattleNetClient.HandleChatEvent(ParseData data)
   at BNSharp.Net.BattleNetClient.Parse()
   at System.Threading.ExecutionContext.Run(ExecutionContext
executionContext, ContextCallback callback, Object state)
   at System.Threading.ThreadHelper.ThreadStart()

Data: {System.Collections.ListDictionaryInternal}
Actual Value: null

What version of the product are you using? On what operating system?
BN# Beta 2

Please provide any additional information below.
I'm developing a bot in C# for fun, and when I join a channel with a
Starcraft Shareware user in it, I get this exception.

Original issue reported on code.google.com by dax...@gmail.com on 7 Mar 2010 at 1:44

GoogleCodeExporter commented 8 years ago
Should be corrected in r67.  There will be a new release of BN# soon.

Original comment by myndf...@valhallalegends.com on 7 Mar 2010 at 8:04

GoogleCodeExporter commented 8 years ago
Seems to be fixed. Thank you. :)

I have a slightly offtopic question though, do/does 
UserProfileRequest/UserProfileKey
support Unicode/UTF8? I was looking at a user's profile and the Unicode 
characters
just show up as question marks. Is that a problem on my end, or did I not set a
property somewhere? Thanks.

Original comment by dax...@gmail.com on 7 Mar 2010 at 11:44

GoogleCodeExporter commented 8 years ago
Fixed in r67.

Original comment by myndf...@valhallalegends.com on 15 Jul 2011 at 1:29