The patch that was supposed to fix everything - now threads correctly, off-by-one somewhere reading corrupted data