From: Fabian Ebner <f.ebner@proxmox.com>
To: pbs-devel@lists.proxmox.com
Subject: [pbs-devel] [PATCH proxmox-backup] Fix #2926: parse_iface_attributes: always break on non-{attribitue, comment} token
Date: Wed, 12 Aug 2020 14:29:29 +0200 [thread overview]
Message-ID: <20200812122929.24380-1-f.ebner@proxmox.com> (raw)
There is no requirement to have at least
a blank line, attribute or comment in between two
interface definitions, e.g.
iface lo inet loopback
iface lo inet6 loopback
Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
---
src/config/network/parser.rs | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/src/config/network/parser.rs b/src/config/network/parser.rs
index 071bbcc7..a97d0f79 100644
--- a/src/config/network/parser.rs
+++ b/src/config/network/parser.rs
@@ -210,9 +210,7 @@ impl <R: BufRead> NetworkParser<R> {
self.eat(Token::Newline)?;
continue;
}
- Token::Newline => break,
- Token::EOF => break,
- unexpected => bail!("unexpected token {:?} (expected iface attribute)", unexpected),
+ _ => break,
}
match self.peek()? {
--
2.20.1
reply other threads:[~2020-08-12 12:29 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200812122929.24380-1-f.ebner@proxmox.com \
--to=f.ebner@proxmox.com \
--cc=pbs-devel@lists.proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal