Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4241822

Problem reading TrueType font file in zh.GBK locale on Solaris 7

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: P3 P3
    • None
    • 1.2.2
    • client-libs
    • 2d
    • sparc
    • solaris_7

      In cricket build S,T, zh.GBK locale,

        When display some chinese ( see the attached program, Draw2DStringCanvas, variable "inputString" ), cause dump core.

       Reproduce:
        1. compile the file
        2. run the program.

      ==========

      This bug is different than the one in bug 4240228 which is a JNI error.
      That bug does not get a chance to show up in this (zh.GBK) locale since
      before it gets that far it fails reading a font file as shown by the
      following stack trace.

      The font in question is the TrueType font file songti.ttf, which
      corresponds to various composite font components in font.properties.zh_GBK, eg
      serif.1=-sun-song-medium-r-normal--*-%d-*-*-c-*-gbk-0

      Assertion failed: size > 0, file
      ../../../../src/share/native/sun/awt/font/fontmanager/fontobjects/fontObject.cpp
      , line 301
      signal ABRT (^[$)A^NMK3v^O) in _kill at 0xff216870
      _kill+0x8: bgeu _kill+0x30
      (dbx) where
      =>[1] _kill(0x0, 0x6, 0xfa44f5d8, 0x2d7298, 0xff389400, 0xff36cd8c), at
      0xff216870
        [2] abort(0xff231f98, 0x7c, 0x7c, 0x7efefeff, 0x81010100, 0xff0000), at
      0xff1b929c
        [3] _assert(0xfa781f30, 0xfa781f3c, 0x12d, 0xff231f98, 0x0, 0x94f721), at
      0xff1b956c
        [4] fileFontObject::readBlock(0x2546f0, 0x4c0d0, 0x0, 0x94f721, 0xfa781e68,
      0x94f721), at 0xfa757350
        [5] PreLoadT2KInputStream(0x94f714, 0x0, 0x0, 0x7c3390, 0x2b, 0x94f721), at
      0xfa732bb0
        [6] PrimeT2KInputStream(0x94f714, 0x35, 0x4c0cc, 0x94f74f, 0x0, 0x0), at
      0xfa732c20
        [7] New_GlyphClass(0x35, 0x94f714, 0x955478, 0x95545c, 0xfa77c4e0, 0x955444),
      at 0xfa734f48
        [8] GetGlyphByIndex(0x7c3b4c, 0x94f714, 0x7c394c, 0x352, 0xfa77c4e0, 0x0), at
      0xfa735a7c
        [9] T2K_RenderGlyphInternal(0x7ef17c, 0x1a9, 0x0, 0x0, 0x0, 0xb), at
      0xfa730cd4
        [10] T2K_RenderGlyph(0xb, 0x7ef17c, 0x0, 0x0, 0x0, 0xb), at 0xfa7323d4
        [11] t2kScalerContext::GenerateMetricsWithImage(0x7ef17c, 0x89ea84, 0x88e710,
      0x89ea98, 0xfa77c4e0, 0x1a9), at 0xfa75d508
        [12] hsGGlyphStrike::GetMetricsWithImage(0x88b578, 0xffff, 0x2e7c, 0x89bc08,
      0xfa77c4e0, 0x89ea84), at 0xfa76318c
        [13] Strike::getMetrics(0x0, 0x10001a9, 0xfa44fdd4, 0xfa44fdcc, 0x0,
      0xfa451f34), at 0xfa74f050
        [14] GlyphVector::positionGlyphsWithImages(0xfa4507dc, 0x90, 0x24, 0xffff,
      0x1, 0x7b2ba8), at 0xfa74d9a4
        [15] Java_sun_awt_font_NativeFontWrapper_drawStringByteDiscrete(0x2d7218,
      0x2d40c0, 0x2d40b0, 0x43b95af8, 0x43960000, 0x2d40bc), at 0xfa743784
        [16] sysInvokeNative(0x2d7218, 0xfa7436c0, 0x2d40b0, 0x2265bc, 0xb,
      0xfa45142c), at 0xff3143e8
        [17] invokeJNISynchronizedNativeMethod(0xff331800, 0x2325ac, 0xff333c00,
      0x2d7218, 0x2d40b0, 0xfa45142c), at 0xff2c0e70
        [18] JITNativeJNIStub(0xfb8aaae8, 0xfb8aa248, 0x43b95af8, 0x43960000,
      0xfb8aa3d8, 0xfb8bf610), at 0xfec9ebf8
        [19] 0x954adc(0xfb8bd0b8, 0xfb8bf418, 0xfb8aa248, 0x43b95af8, 0x43960000,
      0xfb8c51e0), at 0x954adb
        [20] 0x7a3ea4(0xfb8c3798, 0xfb8bfe48, 0xfb8aa248, 0xfb8bf5e8, 0x2, 0x0), at
      0x7a3ea3
        [21] 0x7b3d90(0xfb8c3680, 0xfb8bfe48, 0xfb8aa248, 0x42480000, 0x42480000,
      0x0), at 0x7b3d8f
        [22] 0x7a4d64(0xfb8bfe48, 0xfb8aa248, 0x42480000, 0x42480000, 0x0,
      0xfb8c8880), at 0x7a4d63
        [23] 0x7a339c(0xfb8aa258, 0xfb8bfe48, 0x0, 0x258, 0x258, 0x7f), at 0x7a339b
        [24] 0x72e5a0(0xfb8c4e60, 0xfb8c42f0, 0xfb8bfe48, 0x2f8540, 0xfb8c94c0,
      0xfb8c8880), at 0x72e59f
        [25] 0x73ab2c(0xfb8aa258, 0xfb8c42f0, 0x2d7218, 0x2d7218, 0xfb8a03f8, 0x0), at
      0x73ab2b
        [26] 0x5ca06c(0xfb8aa258, 0xfb8c42f0, 0x2d7218, 0x2d7298, 0x3eddc08d, 0xd), at
      0x5ca06b
        [27] 0x72c5c0(0xfb8c8eb8, 0xfb8c42f0, 0x2d38e0, 0x2c52dc, 0x2c5354,
      0xfffffffc), at 0x72c5bf
        [28] 0x2c5f50(0xfb8c8e20, 0x0, 0x2d7218, 0x2c5160, 0xfb8c8f10, 0xfb8c9060), at
      0x2c5f4f
        [29] 0x2c52a4(0xfb8c8e20, 0xfb8c9058, 0xfb8c8f10, 0x2d4088, 0x2d4fbc, 0x1), at
      0x2c52a3
        [30] 0x2c6bc4(0xfb8c8e20, 0x2d1a68, 0x2d4050, 0xfa451b1a, 0x1, 0x40edb800), at
      0x2c6bc3
        [31] JITInvokeCompiledMethod(0xfb8c8e20, 0x2d1a68, 0x1, 0x2d7218, 0xff2c0880,
      0xfa451e0c), at 0xfec9e978
        [32] callmethod_1(0xfa451e24, 0x2d7218, 0x2d4084, 0x0, 0xfa451e0c, 0x2d4050),
      at 0xff314d64
        [33] do_execute_java_method_vararg(0x2d7218, 0x0, 0x0, 0x0, 0x2d4050,
      0xff32efbd), at 0xff2d003c
        [34] execute_java_dynamic_method(0x2d7218, 0xfb8c8e20, 0xff32efb8, 0xff32efbc,
      0xff3895e0, 0xf6c36300), at 0xff2cf8cc
        [35] saveStackBase(0xff2efa20, 0x2d7218, 0xfb8c8e20, 0x2d7218, 0x0, 0x0), at
      0xff306a30
        [36] start_func(0xff3069b8, 0xffbed558, 0x0, 0x0, 0x0, 0x0), at 0xff376590

            prr Philip Race
            shuwu Shuna Wu (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: