im.pidgin.pidgin: 837d9e290123b6066c5f3e2d27a15eebba987c8f

rlaager at pidgin.im rlaager at pidgin.im
Sun Jan 13 23:23:01 EST 2008


-----------------------------------------------------------------
Revision: 837d9e290123b6066c5f3e2d27a15eebba987c8f
Ancestor: d70a472b98887b5664f526b32c0631f3ca0d6fda
Author: rlaager at pidgin.im
Date: 2008-01-13T21:30:50
Branch: im.pidgin.pidgin

Modified files:
        libpurple/protocols/irc/dcc_send.c

ChangeLog: 

Part of a large patch from o_sukhodolsky to fix some build warnings.
Refs #1344

-------------- next part --------------
============================================================
--- libpurple/protocols/irc/dcc_send.c	54e23061ab525ca1d830befe7012f09973c83ed3
+++ libpurple/protocols/irc/dcc_send.c	dee3b763803a72ba0ca2c68ae9b8515a272217ef
@@ -51,9 +51,14 @@ static void irc_dccsend_recv_ack(PurpleX
  */
 static void irc_dccsend_recv_ack(PurpleXfer *xfer, const guchar *data, size_t size) {
 	unsigned long l;
+	size_t result;
 
 	l = htonl(xfer->bytes_sent);
-	write(xfer->fd, &l, sizeof(l));
+	result = write(xfer->fd, &l, sizeof(l));
+	if (result != sizeof(l)) {
+		purple_debug_error("irc", "unable to send acknowledgement: %s\n", strerror(errno));
+		/* TODO: We should probably close the connection here or something. */
+	}
 }
 
 static void irc_dccsend_recv_init(PurpleXfer *xfer) {


More information about the Commits mailing list