summaryrefslogtreecommitdiff
path: root/sbin
diff options
context:
space:
mode:
authorHenning Brauer <henning@cvs.openbsd.org>2002-11-19 18:51:10 +0000
committerHenning Brauer <henning@cvs.openbsd.org>2002-11-19 18:51:10 +0000
commit2ee72eee21639541d4baa614326d160288a456f8 (patch)
treedd1d916624bc018b63ea2dca0a1ff69abf08b32d /sbin
parent6de774d6cba7e3cd5ab65ca8bd33d4e854d185ac (diff)
only take cbq opts from schedtype if type=CBQ
Diffstat (limited to 'sbin')
-rw-r--r--sbin/pfctl/parse.y7
1 files changed, 5 insertions, 2 deletions
diff --git a/sbin/pfctl/parse.y b/sbin/pfctl/parse.y
index 34a7895dd04..d09907d69f6 100644
--- a/sbin/pfctl/parse.y
+++ b/sbin/pfctl/parse.y
@@ -1,4 +1,4 @@
-/* $OpenBSD: parse.y,v 1.196 2002/11/19 17:31:24 henning Exp $ */
+/* $OpenBSD: parse.y,v 1.197 2002/11/19 18:51:09 henning Exp $ */
/*
* Copyright (c) 2001 Markus Friedl. All rights reserved.
@@ -572,7 +572,10 @@ queuespec : QUEUE STRING bandwidth priority qlimit schedtype qassign {
a.priority = $4;
a.qlimit = $5;
a.scheduler = $6.qtype;
- a.pq_u.cbq_opts.flags = $6.data.cbq_opts.flags;
+ switch (a.scheduler) {
+ case ALTQT_CBQ:
+ a.pq_u.cbq_opts.flags = $6.data.cbq_opts.flags;
+ }
if (expand_queue(&a, $7, $3))
YYERROR;