mirror of
https://github.com/g4klx/MMDVMHost.git
synced 2026-04-04 14:07:36 +00:00
Add more asserts to catch bugs.
This commit is contained in:
parent
14c6208ae5
commit
12fb99c00a
12 changed files with 92 additions and 4 deletions
|
|
@ -25,6 +25,7 @@
|
|||
#include "Log.h"
|
||||
|
||||
#include <cmath>
|
||||
#include <cstdio>
|
||||
#include <cassert>
|
||||
#include <cstdint>
|
||||
|
||||
|
|
@ -858,6 +859,8 @@ bool CModem::setFrequency()
|
|||
|
||||
RESP_TYPE_MMDVM CModem::getResponse(unsigned char *buffer, unsigned int& length)
|
||||
{
|
||||
assert(buffer != NULL);
|
||||
|
||||
// Get the start of the frame or nothing at all
|
||||
int ret = m_serial.read(buffer + 0U, 1U);
|
||||
if (ret < 0) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue