]> git.ipfire.org Git - thirdparty/kea.git/commitdiff
[#3609] Added missing rules
authorFrancis Dupont <fdupont@isc.org>
Wed, 13 Nov 2024 10:04:53 +0000 (11:04 +0100)
committerFrancis Dupont <fdupont@isc.org>
Fri, 22 Nov 2024 08:55:30 +0000 (09:55 +0100)
src/bin/agent/agent_parser.yy
src/bin/dhcp4/dhcp4_parser.yy
src/bin/dhcp6/dhcp6_parser.yy

index e239a58c4d323f94220db0dda71dc1b4a66d7019..228f5f56dc9b794243aa3aff2ef93f139d41923a 100644 (file)
@@ -418,13 +418,17 @@ http_headers: HTTP_HEADERS {
     ctx.leave();
 };
 
-http_header_list: http_header
-                | not_empty_http_header_list COMMA http_header
-                | not_empty_http_header_list COMMA {
-                    ctx.warnAboutExtraCommas(@2);
-                    }
+http_header_list: %empty
+                | not_empty_http_header_list
                 ;
 
+not_empty_http_header_list: http_header
+                          | not_empty_http_header_list COMMA http_header
+                          | not_empty_http_header_list COMMA {
+                              ctx.warnAboutExtraCommas(@2);
+                              }
+                          ;
+
 http_header: LCURLY_BRACKET {
     ElementPtr m(new MapElement(ctx.loc2pos(@1)));
     ctx.stack_.back()->add(m);
index 2d11090ab6b88db227d53f757f12ffd47459e42a..8bc762de500c6d47011698af1dc0e0fd7079e6a6 100644 (file)
@@ -2663,13 +2663,17 @@ http_headers: HTTP_HEADERS {
     ctx.leave();
 };
 
-http_header_list: http_header
-                | not_empty_http_header_list COMMA http_header
-                | not_empty_http_header_list COMMA {
-                    ctx.warnAboutExtraCommas(@2);
-                    }
+http_header_list: %empty
+                | not_empty_http_header_list
                 ;
 
+not_empty_http_header_list: http_header
+                          | not_empty_http_header_list COMMA http_header
+                          | not_empty_http_header_list COMMA {
+                              ctx.warnAboutExtraCommas(@2);
+                              }
+                          ;
+
 http_header: LCURLY_BRACKET {
     ElementPtr m(new MapElement(ctx.loc2pos(@1)));
     ctx.stack_.back()->add(m);
index 05731dcc5377d532ccc3d580a270c5dddc2d0312..b58f10ac013c3b5e75a7a76fa94a7943c8c284b7 100644 (file)
@@ -2805,13 +2805,17 @@ http_headers: HTTP_HEADERS {
     ctx.leave();
 };
 
-http_header_list: http_header
-                | not_empty_http_header_list COMMA http_header
-                | not_empty_http_header_list COMMA {
-                    ctx.warnAboutExtraCommas(@2);
-                    }
+http_header_list: %empty
+                | not_empty_http_header_list
                 ;
 
+not_empty_http_header_list: http_header
+                          | not_empty_http_header_list COMMA http_header
+                          | not_empty_http_header_list COMMA {
+                              ctx.warnAboutExtraCommas(@2);
+                              }
+                          ;
+
 http_header: LCURLY_BRACKET {
     ElementPtr m(new MapElement(ctx.loc2pos(@1)));
     ctx.stack_.back()->add(m);