--- a/jdk/src/java.desktop/share/native/libfontmanager/layout/Features.cpp Tue Dec 15 12:59:00 2015 +0000
+++ b/jdk/src/java.desktop/share/native/libfontmanager/layout/Features.cpp Tue Dec 22 09:50:09 2015 +0300
@@ -43,9 +43,10 @@
LEReferenceToArrayOf<FeatureRecord>
featureRecordArrayRef(base, success, featureRecordArray, SWAPW(featureCount));
- if (featureIndex >= SWAPW(featureCount) || LE_FAILURE(success)) {
- return LEReferenceTo<FeatureTable>();
- }
+ if (featureIndex >= SWAPW(featureCount) || LE_FAILURE(success)) {
+ success = LE_INDEX_OUT_OF_BOUNDS_ERROR;
+ return LEReferenceTo<FeatureTable>();
+ }
Offset featureTableOffset = featureRecordArray[featureIndex].featureTableOffset;