diff --git a/drivers/serial/serial.c b/drivers/serial/serial.c index e070121545..e880f27c44 100644 --- a/drivers/serial/serial.c +++ b/drivers/serial/serial.c @@ -848,7 +848,7 @@ static ssize_t uart_read(FAR struct file *filep, /* Discarding \r ? */ - if ((ch == '\r') & (dev->tc_iflag & IGNCR)) + if ((ch == '\r') && (dev->tc_iflag & IGNCR)) { continue; }