Closed dmoonfire closed 5 years ago
@50Wliu: Would you look at the results and see what you think? All the tests are running green now.
While the first commit gets the encoding working to/from in the various formats, the second addresses some potential buffer overruns I noticed while working with the code. I felt they were different enough to justify a second commit. Mostly they focus on the Hunspell side of things since that is where I noticed the issues.
@nathansobo: Thank you for looking at this.
@dmoonfire Absolutely. This is a huge amount of painstaking work you've done here to make these other dictionaries work. I really appreciate it. :zap:
Just going to try to test this out locally.
Because of how it is structured, an ideal test would be on Windows, Linux, and Mac. Sadly, there are three separate paths of code through this thing, plus you need to have non-ASCII characters to test.
Ah yes, of course. I'm not going to be able to test this very effectively right now because I don't have a Linux setup. Presumably you have tested this as part of the spell-check package?
Checking files uses the encoding of the Hunspell dictionary file.
setlocale(LC_CTYPE, "en_US.utf8")
so word-breaking works properly while looking for splits while checking.