-
Notifications
You must be signed in to change notification settings - Fork 158
Image rewriting check-fails on images with invalid dimensions #1078
Comments
The code:
We should probably just remove this |
The comment on
So in addition to removing the |
Probably better change the if to be <= 0, too? On Wed, May 13, 2015 at 1:44 PM, Jeff Kaufman notifications@github.com
|
Hmm, this was a DCHECK because we should be checking this at the caller. On Wed, May 13, 2015 at 1:41 PM, Jeff Kaufman notifications@github.com
|
It's a little weird that there's a |
On Wed, May 13, 2015 at 1:48 PM, Jeff Kaufman notifications@github.com
The intent was to catch bugs in our dev flow, but fail gracefully on real It looks like this comment talks about what broke things:
|
DCHECK and debug message work for different purpose. DCHECK warns us, only in debug mode, that something bad happened, e.g., Debug message tells us that we can't resize the image at this moment. The I'm not sure if we should remove DCHECK. Huibao On Wed, May 13, 2015 at 1:48 PM, Jeff Kaufman notifications@github.com
|
We need to remove the DCHECK because PageSpeed shouldn't crash on invalid resources, even in debug mode. DCHECKs should only be for programming errors. |
Ah, then blending DCHECK into the if-statement below, as Maks suggested, On Wed, May 13, 2015 at 1:55 PM, Jeff Kaufman notifications@github.com
|
On Wed, May 13, 2015 at 1:52 PM, Jan-Willem Maessen jmaessen@google.com
Right, looking at this some more I think just axing the DCHECK is the right -Jan
|
image_rewrite_filter
on truncated image
When
image_rewrite_filter
optimizes a truncated image it can CHECK-fail:This shouldn't happen. Invalid images should only generate
kInfo
messages and+debug
comments.The text was updated successfully, but these errors were encountered: