1 diff --git a/third_party/lcms/src/cmsplugin.c b/third_party/lcms/src/cmsplugin.c 2 index 79b145d2d..29ddd9a49 100644 3 --- a/third_party/lcms/src/cmsplugin.c 4 +++ b/third_party/lcms/src/cmsplugin.c 5 @@ -179,6 +179,8 @@ cmsBool CMSEXPORT _cmsReadFloat32Number(cmsIOHANDLER* io, cmsFloat32Number* n) 6 7 tmp = _cmsAdjustEndianess32(tmp); 8 *n = *(cmsFloat32Number*) (void*) &tmp; 9 + if (isnan(*n)) 10 + return FALSE; 11 } 12 return TRUE; 13 } 14