]> git.tuebingen.mpg.de Git - paraslash.git/commitdiff
Merge branch 'maint'
authorAndre Noll <maan@tuebingen.mpg.de>
Mon, 31 Jul 2017 09:47:20 +0000 (11:47 +0200)
committerAndre Noll <maan@tuebingen.mpg.de>
Mon, 31 Jul 2017 09:47:20 +0000 (11:47 +0200)
A fix for the udp sender which silences an annoying log message.

* maint:
  udp sender: Send EOF package only once.

udp_send.c

index 8c9eebc94c3a5ef684ef86340b70d3140cd6fcda..0ea95e41993c0c3442ff0fc219c2111f73e5e0f1 100644 (file)
@@ -65,8 +65,9 @@ static void udp_close_target(struct sender_client *sc)
        PARA_NOTICE_LOG("sending FEC EOF\n");
        len = vss_get_fec_eof_packet(&buf);
        /* Ignore write() errors since we are closing the target anyway. */
-       if (write(sc->fd, buf, len) == len)
-               ut->sent_fec_eof = true;
+       if (write(sc->fd, buf, len))
+               do_nothing; /* avoid "ignoring return value" warning */
+       ut->sent_fec_eof = true;
 }
 
 static void udp_delete_target(struct sender_client *sc, const char *msg)