From 64c503aeeb73cb9ebf6340424ec616711750a0a5 Mon Sep 17 00:00:00 2001 From: krw Date: Sat, 18 Jan 2014 01:41:28 +0000 Subject: [PATCH] If ugflag (indicating a character from the file being parsed has been unget()'ed) is set, then properly set the lexchar position back one in get_token() so more error messages put the '^' in the proper spot. --- sbin/dhclient/conflex.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sbin/dhclient/conflex.c b/sbin/dhclient/conflex.c index 9eedf051dd4..59888293d95 100644 --- a/sbin/dhclient/conflex.c +++ b/sbin/dhclient/conflex.c @@ -1,4 +1,4 @@ -/* $OpenBSD: conflex.c,v 1.26 2013/12/18 00:37:59 krw Exp $ */ +/* $OpenBSD: conflex.c,v 1.27 2014/01/18 01:41:28 krw Exp $ */ /* Lexical scanner for dhclient config file. */ @@ -134,7 +134,7 @@ get_token(FILE *cfile) do { l = line; - p = lpos; + p = lpos - ugflag; c = get_char(cfile); -- 2.20.1