1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00

od: don't dump 0-length chunks

This commit is contained in:
Martine Lenders 2016-07-28 11:14:21 +02:00 committed by Martine Lenders
parent 8f890b3790
commit fdc8c39ba2

View File

@ -333,6 +333,10 @@ void od(const void *data, size_t data_len, uint8_t width, uint16_t flags)
uint8_t date_length = _length(flags);
char bytes_format[_log10(date_length) + 7];
if (data_len == 0) {
return;
}
_address_format(address_format, flags);
_bytes_format(bytes_format, flags);