add more sanitization to openjpeg (hopefully fixes issue 2152)