]> git.puffer.fish Git - matthieu/frr.git/commitdiff
lib: fix coverity unused result warning
authorDavid Lamparter <equinox@opensourcerouting.org>
Wed, 7 Jul 2021 12:57:36 +0000 (14:57 +0200)
committerDavid Lamparter <equinox@opensourcerouting.org>
Wed, 7 Jul 2021 12:58:14 +0000 (14:58 +0200)
There's nothing that can be done here with an error.  Try to make
Coverity understand that this is intentional.

(I don't know if the `(void)` will actually fix the coverity warning,
but I don't really have a better way to figure it out beyond just
getting this merged and waiting for a result...)

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
lib/systemd.c

index 7944c2493b0bfb54b54f846d54ae59c2591ab353..2238dc9f3da6d759a97c1b89f3737ffc9800ba5f 100644 (file)
@@ -66,8 +66,8 @@ static void systemd_send_information(const char *info)
                sun.sun_path[0] = '\0';
 
        /* nothing we can do if this errors out... */
-       sendto(sock, info, strlen(info), 0, (struct sockaddr *)&sun,
-              sizeof(sun));
+       (void)sendto(sock, info, strlen(info), 0, (struct sockaddr *)&sun,
+                    sizeof(sun));
 
        close(sock);
 }