summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Borkmann <dborkman@redhat.com>2013-03-27 23:08:00 +0100
committerDaniel Borkmann <dborkman@redhat.com>2013-03-27 23:08:00 +0100
commitb55fde49e9f3e772b62e175cdbbec8f9fcc77567 (patch)
treee6a6e443c75875c5a4cc1a4063bd4650d393fe09
parent12dc4152b5397b3d00f81a8c27853eae15ed5f9c (diff)
trafgen: parser: do not enforce whitesapce
Do not enforce whitespace at the beginning or end of a packet configuration, there's no reason to do so. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
-rw-r--r--trafgen_parser.y6
1 files changed, 3 insertions, 3 deletions
diff --git a/trafgen_parser.y b/trafgen_parser.y
index 37c9a15..16701c7 100644
--- a/trafgen_parser.y
+++ b/trafgen_parser.y
@@ -355,11 +355,11 @@ noenforce_white
;
packet
- : '{' delimiter payload delimiter '}' {
+ : '{' noenforce_white payload noenforce_white '}' {
min_cpu = max_cpu = -1;
realloc_packet();
}
- | K_CPU '(' number cpu_delim number ')' ':' noenforce_white '{' delimiter payload delimiter '}' {
+ | K_CPU '(' number cpu_delim number ')' ':' noenforce_white '{' noenforce_white payload noenforce_white '}' {
min_cpu = $3;
max_cpu = $5;
@@ -372,7 +372,7 @@ packet
realloc_packet();
}
- | K_CPU '(' number ')' ':' noenforce_white '{' delimiter payload delimiter '}' {
+ | K_CPU '(' number ')' ':' noenforce_white '{' noenforce_white payload noenforce_white '}' {
min_cpu = max_cpu = $3;
realloc_packet();
}