Prevent excessive journal logging by wakeup signal
When the application is waiting for timings, it restarts the video to
try and get a signal. Part of this process sends a wake-up signal on
the virtual keyboard and pointer in case host VGA has slept. But if the
host is shut down, this causes repeated errors in the journal as the
HID gadgets return errors.
Fix this by consolidating the keyboard/pointer write functions and
therefore closing the HID gadget file handles when the host is shut
down, preventing further wake-up attempts until host returns.
Change-Id: Id5fe484c976eccefa6a72393d4d6b2b301d28a1a
Signed-off-by: Eddie James <eajames@linux.ibm.com>
diff --git a/ikvm_input.hpp b/ikvm_input.hpp
index 99170ba..9533332 100644
--- a/ikvm_input.hpp
+++ b/ikvm_input.hpp
@@ -87,6 +87,9 @@
*/
static uint8_t keyToScancode(rfbKeySym key);
+ bool writeKeyboard(const uint8_t *report);
+ void writePointer(const uint8_t *report);
+
/* @brief Indicates whether or not a pointer report error has occurred */
bool pointerError;
/* @brief Indicates whether or not to send a keyboard report */