From 4a8e4793ed8d066f94da92a9161dc7f2326682c5 Mon Sep 17 00:00:00 2001 From: Kristof Provost Date: Mon, 22 Oct 2018 04:12:51 +0000 Subject: [PATCH] pfctl: Fix line numbers when \ is used inside "" PR: 201520 Obtained from: OpenBSD MFC after: 2 weeks --- sbin/pfctl/parse.y | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sbin/pfctl/parse.y b/sbin/pfctl/parse.y index c542bf72f703..3602ba8eb5aa 100644 --- a/sbin/pfctl/parse.y +++ b/sbin/pfctl/parse.y @@ -5765,8 +5765,10 @@ top: return (0); if (next == quotec || c == ' ' || c == '\t') c = next; - else if (next == '\n') + else if (next == '\n') { + file->lineno++; continue; + } else lungetc(next); } else if (c == quotec) {