fix errors

This commit is contained in:
Folkert 2021-06-05 12:02:17 +02:00
parent 0c0bf6e4db
commit 749633ddf2

View File

@ -635,11 +635,11 @@ where
let bad_read = r.rxd.amount.read().bits() != buffer.len() as u32;
if bad_write {
return Err(Error::TxBufferTooLong);
return Err(Error::Transmit);
}
if bad_read {
return Err(Error::RxBufferTooLong);
return Err(Error::Receive);
}
Ok(())