aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKrzysztof Kozlowski <krzysztof.kozlowski@canonical.com>2021-07-11 14:51:02 +0200
committerKrzysztof Kozlowski <krzysztof.kozlowski@canonical.com>2021-07-19 12:53:25 +0200
commit1ff9a01dc6b5cdf986bddc23aa85b2d686c9355d (patch)
treefe073f5defe3f066e39eb1b9ef42bf0c52418810
parentd159ccc0b8fcd8904888813e355bec603e121819 (diff)
downloadneard-1ff9a01dc6b5cdf986bddc23aa85b2d686c9355d.tar.gz
unit: use proper pointer to uint8_t in test_snep_read_recv_fragments()
Raw data bytes should be passed as pointer to uint8_t and the calling function already uses that type. This fixes warning: unit/test-snep-read.c: In function ‘test_snep_read_recv_fragments’: unit/test-snep-read.c:408:21: error: pointer of type ‘void *’ used in arithmetic [-Werror=pointer-arith] 408 | memcpy(data_recvd + offset, resp, nbytes); | ^ Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com>
-rw-r--r--unit/test-snep-read.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/unit/test-snep-read.c b/unit/test-snep-read.c
index 5511fec..78db58b 100644
--- a/unit/test-snep-read.c
+++ b/unit/test-snep-read.c
@@ -386,7 +386,7 @@ static bool test_snep_read_send_fragment(size_t frag_len,
* @param[out] data Must be preallocated
*/
static void test_snep_read_recv_fragments(uint32_t frag_len,
- uint32_t remaining_bytes, void *data_recvd)
+ uint32_t remaining_bytes, uint8_t *data_recvd)
{
struct p2p_snep_resp_frame *resp;
uint32_t offset = 0;