提交 778b663e 编写于 作者: J jchen

8020293: JVM crash

Reviewed-by: prr, jgodinez
上级 ad1ae3fd
......@@ -468,9 +468,10 @@ public final class GlyphLayout {
_gvdata.grow();
}
}
if (_gvdata._count < 0) {
break;
}
}
// Break out of the outer for loop if layout fails.
if (_gvdata._count < 0) {
break;
}
}
......
......@@ -104,6 +104,10 @@ Java_sun_font_SunLayoutEngine_initGVIDs
int putGV(JNIEnv* env, jint gmask, jint baseIndex, jobject gvdata, const LayoutEngine* engine, int glyphCount) {
int count = env->GetIntField(gvdata, gvdCountFID);
if (count < 0) {
JNU_ThrowInternalError(env, "count negative");
return 0;
}
jarray glyphArray = (jarray)env->GetObjectField(gvdata, gvdGlyphsFID);
if (IS_NULL(glyphArray)) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册