Revert "Prevent attempted left shift of negative value of possibly maliciously crafted file."

This reverts commit 43d2f3dc70.

Incorrect fix.
This commit is contained in:
ckolivas 2026-02-13 11:56:40 +11:00
parent 63fc40ea93
commit 1ea9a2b3ed

View file

@ -800,11 +800,8 @@ void Predictor::init() {
cr.ht.resize(64, cp[1]);
cr.cm.resize(512);
for (int j=0; j<256; ++j) {
int stretched;
cr.cm[j*2]=1<<15;
stretched = stretch(st.cminit(j)>>8);
if (stretched < 10) error("negative stretched value");
cr.cm[j*2+1]=clamp512k(stretched << 10);
cr.cm[j*2+1]=clamp512k(stretch(st.cminit(j)>>8)<<10);
}
break;
case SSE: // sizebits j start limit