summaryrefslogtreecommitdiff
path: root/src/operator-id.cc
diff options
context:
space:
mode:
authorJannis M. Hoffmann <jannis@fehcom.de>2023-10-11 21:49:37 +0200
committerJannis M. Hoffmann <jannis@fehcom.de>2023-10-11 21:49:37 +0200
commitbc946633e0bcae5fe63528ad743bcc67de7e347d (patch)
tree7a3d127148c13d84e92f38c319fb5aad1e88a6cb /src/operator-id.cc
parent3ea7edf8c9bf7583c426178d4aaff4fb5b736bd2 (diff)
created a Parser class
Diffstat (limited to 'src/operator-id.cc')
-rw-r--r--src/operator-id.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/operator-id.cc b/src/operator-id.cc
index 4d72320..3bc01dc 100644
--- a/src/operator-id.cc
+++ b/src/operator-id.cc
@@ -41,7 +41,7 @@ Operator::ProcessResult IdOperator::process(Depot &depot, Request &command)
return Operator::ProcessResult::OK;
}
-Parser::ParseResult IdOperator::parse(Request &c_in)
+Parser::ParseResult IdOperator::parse(Request &c_in, Parser &p)
{
constexpr auto ACCEPT = Parser::ParseResult::ACCEPT;
@@ -50,7 +50,7 @@ Parser::ParseResult IdOperator::parse(Request &c_in)
if (c_in.getUidMode()) return Parser::ParseResult::REJECT;
Parser::ParseResult res;
- if ((res = expectSPACE()) != ACCEPT && (res = expectCRLF()) != ACCEPT) {
+ if ((res = p.expectSPACE()) != ACCEPT && (res = p.expectCRLF()) != ACCEPT) {
session.setLastError("Expected SPACE or CRLF");
return res;
}