robpaveza / jinxbot

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

Memory stream is not expandable. - DataBuffer.cs #20

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 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.

Callstack:
>   BNSharp.dll!BNSharp.MBNCSUtil.DataBuffer.InsertByteArray(byte[] b 
= {byte[768]}) Line 178 C#
    prjHyperion.exe!prjHyperion.WardenHandler.BNLS_WARDEN_SEND(Byte 
BNLSPacket = 125, BNSharp.MBNCSUtil.DataBuffer IncomingBuffer = 
{BNSharp.MBNCSUtil.DataBuffer}) Line 146 + 0x17 bytes   Basic
    prjHyperion.exe!prjHyperion.WardenHandler.SEND_BNLS_WARDEN_SEED
(Integer Seed = 744498383) Line 119 + 0x10 bytes    Basic
    prjHyperion.exe!prjHyperion.WardenHandler.ConnectionCompleted
(System.IAsyncResult async = {System.Net.Sockets.ConnectAsyncResult}) Line 
47 + 0xc bytes  Basic
    [External Code] 

Conflicting Code:

    Private Sub BNLS_WARDEN_SEND(ByVal BNLSPacket As Byte, ByVal 
IncomingBuffer As DataBuffer)
        Dim pkt As New DataBuffer()
        pkt.InsertInt16(IncomingBuffer.UnderlyingBuffer.Length + 3)
        pkt.InsertByte(&H7D)
        pkt.InsertByteArray(IncomingBuffer.UnderlyingBuffer)
        WardenSocket.Send(pkt.UnderlyingBuffer, 0, SocketFlags.None)
        pkt = Nothing
    End Sub

Conflicting line of code: pkt.InsertByteArray
(IncomingBuffer.UnderlyingBuffer)

What version of the product are you using? On what operating system?
Newest build from SVN - Windows XP

Please provide any additional information below.
Let me know when it's fixed Mynd. - Lead[x86]

Original issue reported on code.google.com by jeff.sh...@gmail.com on 7 Sep 2009 at 11:14

GoogleCodeExporter commented 9 years ago
Changing to be an enhancement request:

Add overload for DataBuffer.InsertByteArray/DataBuffer.Insert to accept the 
following overload:
InsertByteArray(byte[] buffer, int index, int count)
Insert(byte[] buffer, int index, int count)

Original comment by myndf...@valhallalegends.com on 8 Sep 2009 at 8:46