On Thu, Nov 28, 2024 at 18:21:20 +0300, Alexander Kuznetsov wrote: > This function return value is invariant since VIR_EXPAND_N check > removal in 7d2fd6e, so change its type and remove all dependent checks. > > Found by Linux Verification Center (linuxtesting.org) with Svace. > > Reported-by: Pavel Nekrasov <p.nekrasov@xxxxxxxxxxx> > Signed-off-by: Alexander Kuznetsov <kuznetsovam@xxxxxxxxxxxx> > --- > src/remote/remote_driver.c | 10 ++-------- > src/rpc/gendispatch.pl | 5 +---- > src/rpc/virnetclient.c | 3 +-- > src/rpc/virnetclient.h | 2 +- > 4 files changed, 5 insertions(+), 15 deletions(-) ... > diff --git a/src/rpc/virnetclient.c b/src/rpc/virnetclient.c > index f0d30b63ba..39ccbd739c 100644 > --- a/src/rpc/virnetclient.c > +++ b/src/rpc/virnetclient.c > @@ -1065,7 +1065,7 @@ void virNetClientAddProgram(virNetClient *client, > } > > > -int virNetClientAddStream(virNetClient *client, > +void virNetClientAddStream(virNetClient *client, > virNetClientStream *st) Indentation. > { > virObjectLock(client); > @@ -1074,7 +1074,6 @@ int virNetClientAddStream(virNetClient *client, > client->streams[client->nstreams-1] = virObjectRef(st); > > virObjectUnlock(client); > - return 0; > } > > > diff --git a/src/rpc/virnetclient.h b/src/rpc/virnetclient.h > index 7726b57ef4..29099791a0 100644 > --- a/src/rpc/virnetclient.h > +++ b/src/rpc/virnetclient.h > @@ -120,7 +120,7 @@ bool virNetClientHasPassFD(virNetClient *client); > void virNetClientAddProgram(virNetClient *client, > virNetClientProgram *prog); > > -int virNetClientAddStream(virNetClient *client, > +void virNetClientAddStream(virNetClient *client, > virNetClientStream *st); Indentation. Reviewed-by: Jiri Denemark <jdenemar@xxxxxxxxxx>