Dan Kogai <dankogai(_at_)dan(_dot_)co(_dot_)jp> writes:
When calling do_encode() at top of loop dlen is supposed to be number
of bytes _available_ at d, and you have it as number of bytes _used_.
So if we have used most of it and then insert a fallback do_encode()
will zoom off the end of the SV.
I think (too late here for morning person like me to think well) that
d = (U8 *) SvEND(dst);
dlen = SvLEN(dst) - ddone - 1;
is closer to correct ..
I changed Encode.xs accordingly and t/fallback says it is okay. Please
tell me if this will fix the problem you found.
With this I can read Autrijus's email that was dumping to completion.
Also in light of day it seems to be the correct fix.
Dan
--
Nick Ing-Simmons
http://www.ni-s.u-net.com/