diff -r 36b30720a997 -r 91e99bed64ae jdk/src/share/native/sun/font/layout/SingleTableProcessor2.cpp --- a/jdk/src/share/native/sun/font/layout/SingleTableProcessor2.cpp Tue Feb 26 10:07:26 2013 -0800 +++ b/jdk/src/share/native/sun/font/layout/SingleTableProcessor2.cpp Thu Mar 07 10:02:20 2013 -0800 @@ -46,26 +46,27 @@ { } -SingleTableProcessor2::SingleTableProcessor2(const MorphSubtableHeader2 *moprhSubtableHeader) - : NonContextualGlyphSubstitutionProcessor2(moprhSubtableHeader) +SingleTableProcessor2::SingleTableProcessor2(const LEReferenceTo &morphSubtableHeader, LEErrorCode &success) + : NonContextualGlyphSubstitutionProcessor2(morphSubtableHeader, success) { - const NonContextualGlyphSubstitutionHeader2 *header = (const NonContextualGlyphSubstitutionHeader2 *) moprhSubtableHeader; + const LEReferenceTo header(morphSubtableHeader, success); - singleTableLookupTable = (const SingleTableLookupTable *) &header->table; + singleTableLookupTable = LEReferenceTo(morphSubtableHeader, success, &header->table); } SingleTableProcessor2::~SingleTableProcessor2() { } -void SingleTableProcessor2::process(LEGlyphStorage &glyphStorage) +void SingleTableProcessor2::process(LEGlyphStorage &glyphStorage, LEErrorCode &success) { + if(LE_FAILURE(success)) return; const LookupSingle *entries = singleTableLookupTable->entries; le_int32 glyph; le_int32 glyphCount = glyphStorage.getGlyphCount(); for (glyph = 0; glyph < glyphCount; glyph += 1) { - const LookupSingle *lookupSingle = singleTableLookupTable->lookupSingle(entries, glyphStorage[glyph]); + const LookupSingle *lookupSingle = singleTableLookupTable->lookupSingle(singleTableLookupTable, entries, glyphStorage[glyph], success); if (lookupSingle != NULL) { glyphStorage[glyph] = SWAPW(lookupSingle->value);