diff options
author | John-Mark Bell <jmb@netsurf-browser.org> | 2021-08-14 13:59:32 +0100 |
---|---|---|
committer | John-Mark Bell <jmb@netsurf-browser.org> | 2021-08-14 13:59:32 +0100 |
commit | b547911ad6cba76439eeb9cd03a6af3fe0dc6be3 (patch) | |
tree | d8a09a58629d262d6de8004c3e55b2ea6ecccd13 /src/rufl_init.c | |
parent | 5fd0f4c9161c5ab6163386598d04681f12858509 (diff) | |
download | librufl-b547911ad6cba76439eeb9cd03a6af3fe0dc6be3.tar.gz librufl-b547911ad6cba76439eeb9cd03a6af3fe0dc6be3.tar.bz2 |
Accept non-UCS Font Manager rejecting UCS fonts.
If you attempt to use fonts supported by the UCS Font Manager with
a non-UCS Font Manager, this will either work (in a limited way)
or fail because the font data is incomprehensible to the non-UCS
Font Manager. Cope with one particular instance of this.
Diffstat (limited to 'src/rufl_init.c')
-rw-r--r-- | src/rufl_init.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/rufl_init.c b/src/rufl_init.c index 9beb992..3a77588 100644 --- a/src/rufl_init.c +++ b/src/rufl_init.c @@ -886,7 +886,10 @@ rufl_code rufl_init_scan_font_old(unsigned int font_index) rufl_fm_error->errnum != error_FILE_NOT_FOUND && rufl_fm_error->errnum != - error_FONT_ENCODING_NOT_FOUND)) { + error_FONT_ENCODING_NOT_FOUND && + /* Neither is a too modern font */ + rufl_fm_error->errnum != + error_FONT_TOO_MANY_CHUNKS)) { free(charset); for (i = 0; i < num_umaps; i++) free((umap + i)->encoding); @@ -950,7 +953,10 @@ rufl_code rufl_init_scan_font_old(unsigned int font_index) rufl_fm_error->errnum != error_FILE_NOT_FOUND && rufl_fm_error->errnum != - error_FONT_ENCODING_NOT_FOUND)) { + error_FONT_ENCODING_NOT_FOUND && + /* Neither is a too modern font */ + rufl_fm_error->errnum != + error_FONT_TOO_MANY_CHUNKS)) { free(charset); for (i = 0; i < num_umaps; i++) free((umap + i)->encoding); |