speller: prefer 'hunspell' over 'spell', because it can handle UTF-8
Also, 'hunspell' is sensitive to the 'LANG' environment variable, so that spell checking will take place for the language that the user is using, instead of always for English. (This is a behavior change, and some people may not like it, expecting the spell check to occur always for English, but... we'll see.)master
parent
2b8a73348c
commit
4d77e0adbb
|
@ -2373,9 +2373,9 @@ const char *do_int_speller(const char *tempfile_name)
|
|||
close(spell_fd[0]);
|
||||
close(spell_fd[1]);
|
||||
|
||||
/* Now try to run 'spell', and if that fails, try running 'hunspell'. */
|
||||
execlp("spell", "spell", NULL);
|
||||
/* Try to run 'hunspell'; if that fails, fall back to 'spell'. */
|
||||
execlp("hunspell", "hunspell", "-l", NULL);
|
||||
execlp("spell", "spell", NULL);
|
||||
|
||||
/* Indicate failure when neither speller was found. */
|
||||
exit(9);
|
||||
|
|
Loading…
Reference in New Issue