[dpdk-dev] [PATCH v2 1/2] app/crypto-perf: use strcpy for allocated string

De Lara Guarch, Pablo pablo.de.lara.guarch at intel.com
Thu May 17 18:31:29 CEST 2018



> -----Original Message-----
> From: Jerin Jacob [mailto:jerin.jacob at caviumnetworks.com]
> Sent: Wednesday, May 16, 2018 1:28 PM
> To: dev at dpdk.org
> Cc: De Lara Guarch, Pablo <pablo.de.lara.guarch at intel.com>;
> thomas at monjalon.net; Jerin Jacob <jerin.jacob at caviumnetworks.com>;
> Doherty, Declan <declan.doherty at intel.com>; andy at warmcat.com;
> stable at dpdk.org
> Subject: [dpdk-dev] [PATCH v2 1/2] app/crypto-perf: use strcpy for allocated
> string
> 
> inlined from ‘cperf_test_vector_get_from_file’ at
> ../app/test-crypto-perf/cperf_test_vector_parsing.c:578:11:
> ../app/test-crypto-perf/cperf_test_vector_parsing.c:510:3: error:
> ‘strncpy’ output truncated before terminating nul copying as many bytes from a
> string as its length [-Werror=stringop-truncation]
>    strncpy(entry, line, strlen(line));
>    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> ../app/test-crypto-perf/cperf_test_vector_parsing.c:528:5: error:
> ‘strncat’ output truncated before terminating nul copying as many bytes from a
> string as its length [-Werror=stringop-truncation]
>      strncat(entry, line, strlen(line));
>      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> 
> Found this issue with meson build and gcc 8.1.
> 
> Fixes: f8be1786b1b8 ("app/crypto-perf: introduce performance test
> application")
> 
> Cc: declan.doherty at intel.com
> Cc: andy at warmcat.com
> Cc: stable at dpdk.org
> 
> Signed-off-by: Jerin Jacob <jerin.jacob at caviumnetworks.com>
> Acked-by: Pablo de Lara <pablo.de.lara.guarch at intel.com>

Applied to dpdk-next-crypto.
Thanks,

Pablo


More information about the dev mailing list