unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Reuben Thomas <rrt@sc3d.org>
Cc: 49245@debbugs.gnu.org
Subject: bug#49245: Enchant dictionaries list not being correctly set, and other minor fixes
Date: Mon, 28 Jun 2021 15:13:54 +0300	[thread overview]
Message-ID: <83a6nap4ot.fsf@gnu.org> (raw)
In-Reply-To: <CAOnWdogvqyYTYfSz=Q8Ub_pZTkAD37o2xnr-h66H-N6dBSBOmA@mail.gmail.com> (bug-gnu-emacs@gnu.org)

> Date: Sun, 27 Jun 2021 22:20:10 +0100
> From:  Reuben Thomas via "Bug reports for GNU Emacs,
>  the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
> 
> I found a bug recently where, when using Enchant as the back-end for ispell.el, spellchecking was locking up
> for some languages.
> 
> This turned out to be the combination of two problems.
> 
> First, ispell-find-enchant-dictionaries was incorrectly merging ispell-dictionary-base-alist into its result. This
> caused the ispell-set-spellchecker-params to fail to add the correct "-d LANG" flag arguments to the list of
> dictionaries that it used to start Enchant, which in turn meant that the process was started as e.g.
> 
> enchant-2 -d francais # rather than -d fr_FR
> 
> and failed to start properly. I have fixed this by simply removing the incorrect code (patch 0003 attached).
> 
> Secondly, ispell.el failed to notice that it had not actually started an Enchant process, and hung while trying to
> read from it in ispell-accept-output. I fixed this by testing that the process is live before trying to read from or
> write to it (patch 0002 attached).
> 
> Finally, while reading the source code I found an ancient comment that is more of a commit message in
> spirit (it explains how the current code came to be that way, rather than explaining something about how it
> works), so I removed it (patch 0001 attached).
> 
> As usual with my infrequent patches, I would appreciate other eyes on them before I install them, if possible.

OK for the first 2 patches, but please don't remove that comment, it
explains something important, and there's no reason to remove it (or
many other similar comments we have throughout our code).

Thanks.





  reply	other threads:[~2021-06-28 12:13 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-27 21:20 bug#49245: Enchant dictionaries list not being correctly set, and other minor fixes Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-06-28 12:13 ` Eli Zaretskii [this message]
2021-06-28 12:31   ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-06-28 14:37     ` Eli Zaretskii
2021-06-28 17:11       ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-06-28 17:12 ` bug#49245: Closing Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors

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=83a6nap4ot.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=49245@debbugs.gnu.org \
    --cc=rrt@sc3d.org \
    /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).