Bug with DelimiterBasedFrameDecoder + Delimiters.nulDelimiter() or I am doing it wrong?

"이희승 (Trustin Lee)" trustin at gmail.com
Thu Aug 6 02:19:38 EDT 2009


A binary integer often contains NUL (0x00).  For example, an integer
value 1 is presented as four bytes - 0x00, 0x00, 0x00, 0x01.  Hence you
cannot use NUL as a delimiter or you have to make sure the message does
not contain a delimiter in the middle of the message.

HTH,
Trustin

On 07/30/2009 09:55 PM, Nicolas Désy wrote:
> 
> Yes I did read the doc and even looked at the sources.  It is supposed
> to split a ChannelBuffer using another ChannelBuffer(s) as a delimiter,
> right?
> 
> The part I changed is to use the following delimiter instead of
> Delimiters.nulDelimiter() :
> 
>  new ChannelBuffer[]{ 
>    ChannelBuffers.wrappedBuffer("foo".getBytes());
>  }
> 
> 
> Another thing I noticed is that if I send   string+0x00  instead of just
> int+0x00,  it works.  So I presume there is a bug when using a plain old
> integer with a null delimiter.
> 
> 
>> From: mmcgrady at topiatechnology.com
>> To: netty-users at lists.jboss.org
>> Subject: Re: Bug with DelimiterBasedFrameDecoder +
> Delimiters.nulDelimiter() or I am doing it wrong?
>> Date: Wed, 29 Jul 2009 16:19:29 -0700
>>
>> Did you read the javacode documentation for this class? I assume you
>> did but what you say might indicate you did not. Please forgive me if
>> you did and please do not take offense.
>>
>> Mike McGrady
>> Principal Investigator AF081-028 AFRL SBIR
>> Senior Engineer
>> Topia Technology, Inc.
>> 1.253.720.3365
>> mmcgrady at topiatechnology.com
>>
>> _______________________________________________
>> netty-users mailing list
>> netty-users at lists.jboss.org
>> https://lists.jboss.org/mailman/listinfo/netty-users
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> netty-users mailing list
> netty-users at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/netty-users



More information about the netty-users mailing list