summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--utf8.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/utf8.c b/utf8.c
index 7c719cf5..5d99fb1c 100644
--- a/utf8.c
+++ b/utf8.c
@@ -252,7 +252,9 @@ int utf8_encode(wchar_t wch, int (*put)(int ch, mem_t *ctx), mem_t *ctx)
put(0x80 | (wch & 0x3F), ctx);
}
- return 0;
+ uw_throwf(error_s,
+ lit("cannot convert character value #x~x to UTF-8"),
+ num(wch), nao);
}
void utf8_decoder_init(utf8_decoder_t *ud)