Leave a notice in the log when aborting

This commit is contained in:
thorkill 2015-07-01 19:01:42 +02:00
parent 24cea32efb
commit dca3558d05
5 changed files with 32 additions and 11 deletions

View file

@ -873,8 +873,10 @@ bool receive_sptps_record(void *handle, uint8_t type, const void *data, uint16_t
} else {
inpkt.len = ulen + offset;
}
if(inpkt.len > MAXSIZE)
if(inpkt.len > MAXSIZE) {
logger(DEBUG_ALWAYS, LOG_ERR, "receive_sptps_record(): inpkt.len > MAXSIZE. aborting!");
abort();
}
} else {
memcpy(DATA(&inpkt) + offset, data, len);
inpkt.len = len + offset;