From bd7e5d10bab7a00e3b48d42e6a71abeea7fec621 Mon Sep 17 00:00:00 2001 From: Curtis McEnroe Date: Mon, 12 Aug 2019 23:07:16 -0400 Subject: Set up afl-fuzz --- term.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'term.c') diff --git a/term.c b/term.c index c77d4f1..a557725 100644 --- a/term.c +++ b/term.c @@ -554,3 +554,17 @@ fail: fclose(file); return -1; } + +#ifdef TERM_MAIN +#include + +int main(void) { + setlocale(LC_CTYPE, ""); + struct Term *term = termAlloc(24, 80); + wint_t ch; + while (WEOF != (ch = getwchar())) { + termUpdate(term, ch); + } +} + +#endif -- cgit 1.4.1