POSIX FTDI: Fix a bug where closing device successfully returned an error

pull/25/head
Paul Hollinsky 2020-06-24 20:59:53 -04:00
parent dcc44d99ea
commit 25f079b5c6
1 changed files with 1 additions and 1 deletions

View File

@ -91,7 +91,7 @@ bool FTDI::close() {
writeThread.join();
bool ret = ftdi.closeDevice();
if(ret != 0)
if(!ret)
report(APIEvent::Type::DriverFailedToClose, APIEvent::Severity::Error);
uint8_t flush;