20/02/2025 17:27, Stephen Hemminger:
> The buffer tmp is set but never used. This leads to warning
> since the memset could be eliminated by the compiler.
> 
> Signed-off-by: Stephen Hemminger <step...@networkplumber.org>
> ---
>  app/test/test_cmdline_cirbuf.c | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/app/test/test_cmdline_cirbuf.c b/app/test/test_cmdline_cirbuf.c
> index 8ac326cb02..f6361d49e9 100644
> --- a/app/test/test_cmdline_cirbuf.c
> +++ b/app/test/test_cmdline_cirbuf.c
> @@ -251,11 +251,9 @@ test_cirbuf_string_add_del_reverse(void)
>  {
>       struct cirbuf cb;
>       char buf[CMDLINE_TEST_BUFSIZE];
> -     char tmp[CMDLINE_TEST_BUFSIZE];
>  
>       /* initialize buffers */
>       memset(buf, 0, sizeof(buf));
> -     memset(tmp, 0, sizeof(tmp));

Another memset was missed in this function.
Fixed while merging.


Reply via email to