Yes, I believe that the C code is doing what your documentation describes. However, your assumption about return values may be incorrect. Looking at the C code, I believe the function returns 0 if the checksum succeeds (is correct) and 1 if the checksum fails (is incorrect).
See if that matches your sample results.
Not documented in the C code is what happens if bufflen is less than 5 or greater than the actual size of the buff. You may have trouble getting Perl to replicate the behavior in these cases (accessing random memory on the stack).
--
Eric Hammond
| [reply] |