diff options
author | Lorenz Meier <lm@inf.ethz.ch> | 2015-01-20 14:14:23 +0100 |
---|---|---|
committer | Lorenz Meier <lm@inf.ethz.ch> | 2015-01-20 14:14:23 +0100 |
commit | c04f8705643962d9099517475c110ebb511b7e8b (patch) | |
tree | c130f87b1cc112004977d6a3da6cc759afb6f530 | |
parent | f1a53f5152da68e48f7dea8bb0fc3a03e4effd12 (diff) | |
download | px4-firmware-c04f8705643962d9099517475c110ebb511b7e8b.tar.gz px4-firmware-c04f8705643962d9099517475c110ebb511b7e8b.tar.bz2 px4-firmware-c04f8705643962d9099517475c110ebb511b7e8b.zip |
Fix CID 12427 & 12438
-rw-r--r-- | src/drivers/px4io/px4io.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/drivers/px4io/px4io.cpp b/src/drivers/px4io/px4io.cpp index f98010f68..82c7bf2c4 100644 --- a/src/drivers/px4io/px4io.cpp +++ b/src/drivers/px4io/px4io.cpp @@ -3007,8 +3007,9 @@ monitor(void) poll(fds, 1, 2000); if (fds[0].revents == POLLIN) { - int c; - read(0, &c, 1); + /* control logic is to cancel with any key */ + char c; + (void)read(0, &c, 1); if (cancels-- == 0) { printf("\033[2J\033[H"); /* move cursor home and clear screen */ |