# HG changeset patch # User prr # Date 1433965398 25200 # Node ID a1c315dd1554cac4460831b3e08693fc46ca510c # Parent 15d0fd22179a335af595cf2f354d61f6cad59a68 8081756: Mastering Matrix Manipulations Reviewed-by: serb, bae, mschoene diff -r 15d0fd22179a -r a1c315dd1554 jdk/src/java.desktop/share/native/liblcms/cmsopt.c --- a/jdk/src/java.desktop/share/native/liblcms/cmsopt.c Wed Jun 10 17:18:10 2015 +0300 +++ b/jdk/src/java.desktop/share/native/liblcms/cmsopt.c Wed Jun 10 12:43:18 2015 -0700 @@ -260,7 +260,9 @@ cmsStage* Multmat = cmsStageAllocMatrix(Lut->ContextID, 3, 3, (const cmsFloat64Number*) &res, NULL); // Recover the chain - Multmat->Next = chain; + if (Multmat != NULL) { + Multmat->Next = chain; + } *pt1 = Multmat; }