summaryrefslogtreecommitdiff
path: root/command_processor.h
diff options
context:
space:
mode:
Diffstat (limited to 'command_processor.h')
-rw-r--r--command_processor.h9
1 files changed, 5 insertions, 4 deletions
diff --git a/command_processor.h b/command_processor.h
index ae9d91c..1ad1719 100644
--- a/command_processor.h
+++ b/command_processor.h
@@ -41,6 +41,8 @@ class CommandProcessor {
// This method allows tests to provide a MockOs.
CommandProcessor(size_t buffer_size_bytes, std::unique_ptr<Os> os);
+ virtual ~CommandProcessor();
+
// Processes the given command, with the given file descriptor. The effect of
// this call depends on the contents of |input_buf|. In particular, depending
// on the command, |fd| may be used for reading or writing, or |fd| may be
@@ -48,11 +50,10 @@ class CommandProcessor {
// returns, in all cases.
//
// (Ideally, we might want to take |fd| as a unique_fd. Unfortunately,
- // GoogleMock doesn't deal well with move-only parameters. And we'll
- // want to mock this method, eventually.
+ // GoogleMock doesn't deal well with move-only parameters.
// https://github.com/google/googletest/issues/395)
- bool ProcessCommand(NONNULL const void* input_buf, size_t n_bytes_read,
- int fd);
+ virtual bool ProcessCommand(NONNULL const void* input_buf,
+ size_t n_bytes_read, int fd);
private:
// Copies |command_buffer| into the log buffer. Returns true if the