When loading a Type 1 font, remember to terminate the linked list we load
[sgt/halibut] / bk_text.c
index d7c539c..6df426e 100644 (file)
--- a/bk_text.c
+++ b/bk_text.c
@@ -126,9 +126,7 @@ static textconfig text_configure(paragraph *source) {
            if (!ustricmp(p->keyword, L"text-indent")) {
                ret.indent = utoi(uadv(p->keyword));
            } else if (!ustricmp(p->keyword, L"text-charset")) {
-               char *csname = utoa_dup(uadv(p->keyword), CS_ASCII);
-               ret.charset = charset_from_localenc(csname);
-               sfree(csname);
+               ret.charset = charset_from_ustr(&p->fpos, uadv(p->keyword));
            } else if (!ustricmp(p->keyword, L"text-filename")) {
                sfree(ret.filename);
                ret.filename = dupstr(adv(p->origkeyword));