Hi,
* Nico Golde <[email protected]> [2010-07-20 00:29]:
> * Holger Hans Peter Freyther <[email protected]> [2010-07-19 22:13]:
> > On 07/10/2010 12:56 AM, Nico Golde wrote:
[...]
> > I used the current result of the encoding and there seems to
> > be at least one more bug with our encoding routines. We append
> > zero byte(s) at the end that are not touched by the encoding
> > routine but covered by the length.
> > 
> > A nice way to test this is to change the memset(something, 0 to
> > memset(something, 23 and see how it is going to change.
> > 
> > Would you be interested in changing that?
> 
> I just looked into this and if I'm not mistaken this is no 
> bug in the encoding but just a bug when comparing the 
> encoded result. The current code memcmp's n bytes where n is 
> the result of gsm_7bit_encode() with the input string 
> bytewise. The problem with this is that the function returns 
> the number of septets not octets. Attached is a patch for 
> the test code that should fix this.

Sorry, forget what I wrote here, it's just wrong :)

Cheers
Nico

Reply via email to