qemu-trivial
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] audio/ossaudio: Fix compiler warning with -Wshadow


From: Philippe Mathieu-Daudé
Subject: Re: [PATCH] audio/ossaudio: Fix compiler warning with -Wshadow
Date: Wed, 4 Oct 2023 10:55:19 +0200
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.15.1

On 4/10/23 10:39, Thomas Huth wrote:
The "err" variable is only used twice in this code, in a very
local fashion of first assigning it and then checking it in the
next line. So there is no need to declare this variable a second
time in the innermost block, we can re-use the variable that is
declared at the beginning of the function. This fixes the compiler
warning that occurs with "-Wshadow".

Signed-off-by: Thomas Huth <thuth@redhat.com>
---
  audio/ossaudio.c | 1 -
  1 file changed, 1 deletion(-)

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>




reply via email to

[Prev in Thread] Current Thread [Next in Thread]