unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Robert Pluim <rpluim@gmail.com>
To: handa <handa@gnu.org>
Cc: 49066@debbugs.gnu.org, eggert@cs.ucla.edu, larsi@gnus.org,
	mvsfrasson@gmail.com
Subject: bug#49066: 26.3; Segmentation fault on specific utf8 string
Date: Mon, 05 Jul 2021 11:28:43 +0200	[thread overview]
Message-ID: <87k0m5cdo4.fsf@gmail.com> (raw)
In-Reply-To: <87zgv4cfu6.fsf@gnu.org> (handa@gnu.org's message of "Sat, 03 Jul 2021 11:05:05 +0900")

>>>>> On Sat, 03 Jul 2021 11:05:05 +0900, handa <handa@gnu.org> said:

    handa> In article <83bl7qp52q.fsf@gnu.org>, Eli Zaretskii <eliz@gnu.org> writes:
    >> > With the patch it still crashes for me in emacs-master with harfbuzz disabled:

    >> Too bad.
    >> Kenichi, any suggestions?

    handa> I checked the code again, and found that it was a fault of m17n-lib
    handa> which was not robust enough to handle an OTF table that is different
    handa> from what the library expects.

    handa> Here is a revised patch to handle such a case.  Could you please try it?

Thanks, that fixes the crash, and results in the ZWNJ being composed.

    >> Btw, I think there's a bug in those patterns: ZWJ and ZWNJ shouldn't
    >> compose unless they are followed by a character.  See section 12.2 in
    >> the Unicode Standard.

    handa> Even if they should not be composed with, we must include them in the
    handa> string to shape because their existence may change the glyph of the
    handa> previous character.  A shaper (m17n-lib or harfbuzz) must return a glyph
    handa> string that has an independent grapheme cluster for the last ZWJ/ZWNJ.

    handa> At the time of developing m17n-lib, the above rule was not clear.  To
    handa> conform to that rule, please to put the attached BNG2-OTF.flt under the
    handa> directory ~/.m17n.d/.

I believe you, but I did not test this specifically.

Robert
-- 





  reply	other threads:[~2021-07-05  9:28 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-16 21:07 bug#49066: 26.3; Segmentation fault on specific utf8 string Miguel V. S. Frasson
2021-06-16 21:12 ` Lars Ingebrigtsen
2021-06-17  6:43   ` Eli Zaretskii
2021-06-17  7:43     ` Robert Pluim
2021-06-17  8:13       ` Eli Zaretskii
2021-06-17 13:07         ` Robert Pluim
2021-06-17 13:59           ` Eli Zaretskii
2021-06-17 15:04             ` Eli Zaretskii
2021-06-27  2:29             ` handa
2021-06-27  6:20               ` Eli Zaretskii
2021-06-27 18:02                 ` Paul Eggert
2021-06-27 19:15                   ` Eli Zaretskii
2021-06-28 10:56                     ` Robert Pluim
2021-06-28 12:05                       ` Eli Zaretskii
2021-07-03  2:05                         ` handa
2021-07-05  9:28                           ` Robert Pluim [this message]
2021-07-20 12:23                             ` Lars Ingebrigtsen
2021-06-16 21:22 ` bug#49066: file foo Miguel V. S. Frasson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87k0m5cdo4.fsf@gmail.com \
    --to=rpluim@gmail.com \
    --cc=49066@debbugs.gnu.org \
    --cc=eggert@cs.ucla.edu \
    --cc=handa@gnu.org \
    --cc=larsi@gnus.org \
    --cc=mvsfrasson@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).