Reece H. Dunn
22270bd259
Fix reading hash table entries > 128.
This is related to ebfa320956169e3419234b72fee51bd596867661, but
when reading the hash chain entry length, not writing it.
If char is signed, then before this change the length would be
negative, causing problems loading the dictionary.
8 years ago
Reece H. Dunn
ebfa320956
Fix storing the line length in the hash chain.
The length is stored as the first byte in the output from
compile_line. As the data pointer is char, if char is signed then
length could be negative resulting in undefined behaviour. This
commit fixes the issue by reading and writing that byte as a
uint8_t.
This bug was caused by 2a00ca79f6
.
Previously, the entries could only be a maximum of 128 bytes, and
would not be negative on platforms with signed chars. That
commit was made to support long emoji entries, especially for
non-Latin languages where the utf-8 representations could be
longer than 128 bytes.
This change also adds some documentation to make it clearer what
is going on. NOTE: The code should really be using actual struct
objects instead of writing to opaque char buffers.
Reported by Reef Turner <[email protected] >
8 years ago
Reece H. Dunn
e7ac4b819d
hash_counts is never used, so remove it.
Reported by Reef Turner <[email protected] >
8 years ago
Reece H. Dunn
921229259d
Use int to store the value from GetFileLength.
This fixes the clang warning:
comparison of unsigned expression < 0 is always false
[-Wtautological-compare]
Reported by Reef Turner <[email protected] >
8 years ago
Reef Turner
0994206f71
address buffer overrun when dict listx file has no trailling newline
See ar_listx as an example.
8 years ago
Reece H. Dunn
1cb4115eab
Add Emoji_Component support from emoji-data.txt.
8 years ago
Reece H. Dunn
18d3a0819a
Unicode Emoji 5.0
8 years ago
Reece H. Dunn
023ebace9a
Add Regional_Indicator support from PropList.txt.
8 years ago
Reece H. Dunn
4c1ff765f1
Unicode Character Data 10.0.0
8 years ago
Reece H. Dunn
0b56f2e5bc
Use C-style comments to support using a C89 compiler.
8 years ago
yorkie
db79bd12eb
build, encoding: include stdint
The stdint.h is not included when building test, then including this module inside encoding.h
8 years ago
yorkie
949de3f80f
build: fix duplicated symbol when linking
8 years ago
Reece H. Dunn
f946c6e227
windows: fix building the bs, hr and sr languages
8 years ago
Reece H. Dunn
2a00ca79f6
Increase dict_line to support long emoji entries.
8 years ago
Reece H. Dunn
d5d980862e
Guard against overflowing the dict_line bounds when compiling dictionary files.
8 years ago
Reece H. Dunn
4771cd4d5e
windows: fix building the Chinese (Cantonese) voice
8 years ago
Reece H. Dunn
8d1ff99847
windows: fix building the Japanese voice
8 years ago
Reece H. Dunn
ebe7ce827b
windows: the installer depends on the data (voice, language) files
8 years ago
Reece H. Dunn
b16ff0119e
windows: update the project files to Visual Studio 2017
8 years ago
Reece H. Dunn
416bc66dca
Fix pronouncing replacement text that is dependent on start of word rules.
8 years ago
Reece H. Dunn
7accbcd498
Only update the sample rate if the mbrola voice was successfully loaded.
8 years ago
Reece H. Dunn
e41a78d819
Report the actual error from LoadMbrolaTable when loading the mbrola voice.
8 years ago
Reece H. Dunn
801753bdbd
[Windows] Fix installing the cs, pl, ru and sk language files after fixing their language family.
8 years ago
Reece H. Dunn
133d44039a
en: (emoji) -- zwj sequences - gendered gestures (Unicode Emoji 5.0).
8 years ago
Reece H. Dunn
c163f19360
en: (emoji) -- zwj sequences - gendered activity (Unicode Emoji 5.0).
8 years ago
Reece H. Dunn
8dde51ca87
Remove the now unused emoji_zwj specifier.
8 years ago
Reece H. Dunn
ea34ebcad5
en: (emoji) -- zwj sequences - gendered role (Unicode Emoji 5.0).
8 years ago
Reece H. Dunn
fbd2e679fc
Don't crash if loading the default voice fails.
8 years ago
Reece H. Dunn
dced9f58fd
Clean up the decoder memory in espeak_Terminate.
8 years ago
Reece H. Dunn
63e2826753
Ensure that the old translator is not used after calling espeak_Terminate.
8 years ago
Reece H. Dunn
ae6116bf97
Fix calling espeak_Synth without first setting a voice, with tests.
8 years ago
Reece H. Dunn
6ab1314843
Move outbuf_size to where it is actually used.
8 years ago
Reece H. Dunn
9fc2efb1fa
Don't re-initialize my_audio if espeak_ng_InitializeOutput is called multiple times.
8 years ago
Reece H. Dunn
ee07eaa733
Support capitalized words in text-based replacements. This is important in languages like German that differentiate pronunciation on case. Even English does this (e.g. Polish/polish).
8 years ago
Reece H. Dunn
0de7b6c7db
en: (emoji) -- Unicode Emoji 4.0 (Emoji Gender Specifiers)
8 years ago
Reece H. Dunn
7e85b36b4d
en: (emoji) -- Unicode Emoji 4.0 (Emoji Roles)
8 years ago
Valdis Vitolins
aea34ae5d9
Issue #100 Manipuri: Fix for wrongly pronounced numbers
8 years ago
chrislm
3b0771df5a
Decimal numbers in Spanish
8 years ago
Reece H. Dunn
dcc43bc30a
Support _emoji dictionary lists for symbol and emoji pronunciations.
8 years ago
Reece H. Dunn
fe14c83372
Support multi-word text replacements in dictionary list files.
8 years ago
Reece H. Dunn
05cab4f2dc
Extend compile_line to include pronunciation data after a space (e.g. multi-word pronunciation replacements).
8 years ago
Reece H. Dunn
32912d6565
Add Emoji_Modifier_Base from emoji-data.txt.
8 years ago
Reece H. Dunn
4b874e6dbd
Add Emoji_Modifier from emoji-data.txt.
8 years ago
Reece H. Dunn
35ad249760
Add Emoji_Presentation from emoji-data.txt.
8 years ago
Reece H. Dunn
f93b98a69d
Add Emoji support from emoji-data.txt.
8 years ago
Reece H. Dunn
48ca2239bb
Fix non-Latin character languages falling back to English when reading Latin characters.
8 years ago
Reece H. Dunn
94376c2d5f
Use an enum and named values for the steps in compile_line to make the logic easier to read.
8 years ago
Reece H. Dunn
efd1df3206
Build a test version of libespeak-ng that exposes the internal APIs.
8 years ago
Reece H. Dunn
85801fc1e3
Remove the now unused dictdialect functionality from the code.
8 years ago
Reece H. Dunn
2f8f125c68
Remove voice/language support for alphabet2.
This is not used by any of the espeak-ng voices and languages.
Additionally, this functionality would be superceded by support
for specifying the language used by different scripts in the
language argument on the command line.
8 years ago