mirror of
https://gitlab.isc.org/isc-projects/kea
synced 2025-08-31 14:05:33 +00:00
[master] Tried another way to fix UDP flex overload
This commit is contained in:
@@ -207,6 +207,16 @@ ControlCharacterFill [^"\\]|\\{JSONEscapeSequence}
|
||||
}
|
||||
}
|
||||
|
||||
\"udp\" {
|
||||
switch(driver.ctx_) {
|
||||
case isc::dhcp::Parser4Context::DHCP_SOCKET_TYPE:
|
||||
case isc::dhcp::Parser4Context::NCR_PROTOCOL:
|
||||
return isc::dhcp::Dhcp4Parser::make_UDP(driver.loc_);
|
||||
default:
|
||||
return isc::dhcp::Dhcp4Parser::make_STRING("udp", driver.loc_);
|
||||
}
|
||||
}
|
||||
|
||||
\"interfaces\" {
|
||||
switch(driver.ctx_) {
|
||||
case isc::dhcp::Parser4Context::INTERFACES_CONFIG:
|
||||
@@ -1017,10 +1027,8 @@ ControlCharacterFill [^"\\]|\\{JSONEscapeSequence}
|
||||
|
||||
(?i:\"UDP\") {
|
||||
/* dhcp-ddns value keywords are case insensitive */
|
||||
if ((driver.ctx_ == isc::dhcp::Parser4Context::NCR_PROTOCOL) ||
|
||||
((driver.ctx_ == isc::dhcp::Parser4Context::DHCP_SOCKET_TYPE) &&
|
||||
(yytext == "\"udp\""))) {
|
||||
return isc::dhcp::Dhcp4Parser::make_UDP(driver.loc_);
|
||||
if (driver.ctx_ == isc::dhcp::Parser4Context::NCR_PROTOCOL) {
|
||||
return isc::dhcp::Dhcp4Parser::make_UDP(driver.loc_);
|
||||
}
|
||||
std::string tmp(yytext+1);
|
||||
tmp.resize(tmp.size() - 1);
|
||||
|
Reference in New Issue
Block a user