Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-45963

QFontEngineFT crash when using non-scalable fonts

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P1: Critical
    • 5.6.0 RC
    • 5.3.2, 5.5.1, 5.6.0 RC
    • GUI: Font handling
    • None
    • Linux 3.16.7, Debian Jessie amd64, custom fontconfig settings to trigger bug.
    • a67a905190b85b53c30c9cb800b5e282d9364179

    Description

      On Linux, when a non-scalable font is used, the application will segfault with a floating point exception.

      This may be due to a division by zero in qfontengine_ft.cpp, line 1203 caused by units_by_EM being zero for non-scalable (bitmap) fonts.

      To trigger/reproduce this problem, I installed the Noto Color Emoji bitmap font and changed some fontconfig properties to activate and give priority to that font. For example, this meant using a .config/fontconfig/fonts.conf that looked like:

      <?xml version="1.0"?>
      <!DOCTYPE fontconfig SYSTEM "fonts.dtd">
      <fontconfig>
       <match target="pattern">
          <test name="prgname">
            <string>hipchat.bin</string>
          </test>
          <edit name="family" mode="prepend_first">
            <string>Noto Color Emoji</string>
          </edit>
        </match>
      </fontconfig>
      

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            esabraha Eskil Abrahamsen Blomfeldt
            deuxpi Philippe Gauthier
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes