From 030de9f979a77d6a67d1f823d8ba4c01217e5e0d Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Wed, 4 Mar 2015 00:09:03 +0100 Subject: sizeof vs hardcoded length --- software/hhd70dongle/hhd70dongle.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/software/hhd70dongle/hhd70dongle.c b/software/hhd70dongle/hhd70dongle.c index ad73195..30153be 100644 --- a/software/hhd70dongle/hhd70dongle.c +++ b/software/hhd70dongle/hhd70dongle.c @@ -234,7 +234,7 @@ static void handle_cmd(uint8_t cmd) } } -uint8_t tempdata[255]; +uint8_t tempdata[256]; static void do_receive_task(uint8_t first) { @@ -264,7 +264,7 @@ static void do_receive_task(uint8_t first) } } - uint8_t r = cc1101_read_rxfifo(tempdata, 255); + uint8_t r = cc1101_read_rxfifo(tempdata, sizeof(tempdata)); if(r) { uint8_t i; for(i=0; i