]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
rpc: Remove duplicate check from filter function return.
authorJulio Faracco <jcfaracco@gmail.com>
Wed, 14 Nov 2018 17:49:00 +0000 (15:49 -0200)
committerJohn Ferlan <jferlan@redhat.com>
Wed, 14 Nov 2018 20:11:51 +0000 (15:11 -0500)
This is a simple removal of a duplicated check of the return of the
filter function. There is a nested conditional checking exactly the same
thing since commit c9ede1cf removed the (ret > 0) check condition.

Signed-off-by: Julio Faracco <jcfaracco@gmail.com>
Reviewed-by: John Ferlan <jferlan@redhat.com>
src/rpc/virnetserverclient.c

index 97cf126f56a09ec6f193c7051011b3e71cac5a56..778cd1afc04203edfb4e45613ee6b2d9f515b11d 100644 (file)
@@ -1288,8 +1288,7 @@ static virNetMessagePtr virNetServerClientDispatchRead(virNetServerClientPtr cli
                 if (ret < 0) {
                     virNetMessageFree(msg);
                     msg = NULL;
-                    if (ret < 0)
-                        client->wantClose = true;
+                    client->wantClose = true;
                     break;
                 }
                 if (ret > 0) {