From 4ac6265c00a615f1c73a9e93009e46865afcdfd9 Mon Sep 17 00:00:00 2001 From: Ingo Schwarze Date: Sat, 31 Jan 2015 00:12:41 +0000 Subject: Use relative offsets instead of absolute pointers for the terminal font stack. The latter fail after the stack is grown with realloc(). Fixing an assertion failure found by jsg@ with afl some time ago (test case number 51). --- term.h | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'term.h') diff --git a/term.h b/term.h index 34249df6..b65524b6 100644 --- a/term.h +++ b/term.h @@ -1,4 +1,4 @@ -/* $Id: term.h,v 1.110 2014/12/23 13:48:57 schwarze Exp $ */ +/* $Id: term.h,v 1.111 2015/01/31 00:12:41 schwarze Exp $ */ /* * Copyright (c) 2008, 2009, 2010, 2011 Kristaps Dzonsons * Copyright (c) 2011, 2012, 2013, 2014 Ingo Schwarze @@ -126,10 +126,9 @@ int term_vspan(const struct termp *, const struct roffsu *); size_t term_strlen(const struct termp *, const char *); size_t term_len(const struct termp *, size_t); -const enum termfont *term_fontq(struct termp *); void term_fontpush(struct termp *, enum termfont); void term_fontpop(struct termp *); -void term_fontpopq(struct termp *, const enum termfont *); +void term_fontpopq(struct termp *, int); void term_fontrepl(struct termp *, enum termfont); void term_fontlast(struct termp *); -- cgit v1.2.3-56-ge451