In particular, this makes the jpegparse unit test pass again. Also add a debug statement. Fixes #622690.