Fix prev cleanup.

This commit is contained in:
Howard Chu 2007-11-30 18:32:42 +00:00
parent 55f6387214
commit 88ea88feeb

View File

@ -640,8 +640,8 @@ scale( int new, lutil_int_decnum *prev, unsigned char *tmp )
}
}
out = tmp + prev->bufsiz - 1;
for ( i = 0; new ; i-- ) {
out = tmp + prev->bufsiz;
for ( i = -1; new ; i-- ) {
new += out[i];
out[i] = new & 0xff;
new >>= 8;