[libvirt] [PATCH 2/2] util: virNetDevBandwidthPlug: Drop ATTRIBUTE_UNUSED(4)
Michal Privoznik
mprivozn at redhat.com
Mon Nov 25 08:28:09 UTC 2019
On 11/22/19 5:09 PM, Erik Skultety wrote:
> Since we know for sure that the @bandwidth parameter is properly handled
> in networkCheckBandwidth (@ifaceBand), it cannot ever be NULL, but
> coverity doesn't see this fact. In order to prevent coverity from
> reporting a false positive here, drop ATTRIBUTE_UNUSED for this specific
> argument - virNetDevBandwidthPlug is also called from a single place only
>
> Signed-off-by: Erik Skultety <eskultet at redhat.com>
> ---
> src/util/virnetdevbandwidth.h | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/src/util/virnetdevbandwidth.h b/src/util/virnetdevbandwidth.h
> index 19323c5ed2..59d7513286 100644
> --- a/src/util/virnetdevbandwidth.h
> +++ b/src/util/virnetdevbandwidth.h
> @@ -55,8 +55,7 @@ int virNetDevBandwidthPlug(const char *brname,
> const virMacAddr *ifmac_ptr,
> virNetDevBandwidthPtr bandwidth,
> unsigned int id)
> - ATTRIBUTE_NONNULL(1) ATTRIBUTE_NONNULL(3) ATTRIBUTE_NONNULL(4)
> - G_GNUC_WARN_UNUSED_RESULT;
> + ATTRIBUTE_NONNULL(1) ATTRIBUTE_NONNULL(3) G_GNUC_WARN_UNUSED_RESULT;
>
> int virNetDevBandwidthUnplug(const char *brname,
> unsigned int id)
>
Le sigh.
Reviewed-by: Michal Privoznik <mprivozn at redhat.com>
Michal
More information about the libvir-list
mailing list