Bump up to 1.99.13.
authorJoe Shaw <joe@ximian.com>
Fri, 7 Mar 2003 23:02:26 +0000 (23:02 +0000)
committerJoe Shaw <joeshaw@src.gnome.org>
Fri, 7 Mar 2003 23:02:26 +0000 (23:02 +0000)
2003-03-07  Joe Shaw  <joe@ximian.com>

* configure.in: Bump up to 1.99.13.

* libsoup/soup-context.c (soup_context_connect_cb): Add G_IO_IN to
the list of conditions to watch.  If the remote end hangs up the
connection, we'll get a successful read of 0 bytes, not a HUP.
The connection will have to be released by the point we check for
it in connection_death().

* libsoup/soup-queue.c (soup_queue_error_cb): Get rid of some
(apparently) errant resetting of the read and write tags.  I think
this might have been causing some reentrancy and crashes.

* libsoup/soup-socket.c (soup_socket_get_iochannel): Set the IO
channel to NULL encoding and not buffered.

* libsoup/soup-transfer.c (soup_transfer_read_cb): Remove some
incorrect comments.

ChangeLog
configure.in
libsoup/soup-context.c
libsoup/soup-queue.c
libsoup/soup-socket.c
libsoup/soup-transfer.c

index e8e518d..5539368 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,23 @@
+2003-03-07  Joe Shaw  <joe@ximian.com>
+
+       * configure.in: Bump up to 1.99.13.
+
+       * libsoup/soup-context.c (soup_context_connect_cb): Add G_IO_IN to
+       the list of conditions to watch.  If the remote end hangs up the
+       connection, we'll get a successful read of 0 bytes, not a HUP.
+       The connection will have to be released by the point we check for
+       it in connection_death().
+
+       * libsoup/soup-queue.c (soup_queue_error_cb): Get rid of some
+       (apparently) errant resetting of the read and write tags.  I think
+       this might have been causing some reentrancy and crashes.
+
+       * libsoup/soup-socket.c (soup_socket_get_iochannel): Set the IO
+       channel to NULL encoding and not buffered.
+
+       * libsoup/soup-transfer.c (soup_transfer_read_cb): Remove some
+       incorrect comments.
+
 2003-02-28  Joe Shaw  <joe@ximian.com>
 
        * configure.in: Bump up to 1.99.12.
index 56ab42d..5b4d76a 100644 (file)
@@ -4,7 +4,7 @@ dnl *******************************************
 
 AC_INIT(libsoup/soup.h)
 
-AM_INIT_AUTOMAKE(libsoup, 1.99.12)
+AM_INIT_AUTOMAKE(libsoup, 1.99.13)
 AM_CONFIG_HEADER(config.h)
 AM_MAINTAINER_MODE
 AC_PROG_MAKE_SET
index d834932..ab927c3 100644 (file)
@@ -352,7 +352,7 @@ soup_context_connect_cb (SoupSocket              *socket,
                chan = soup_connection_get_iochannel (new_conn);
                new_conn->death_tag = 
                        g_io_add_watch (chan,
-                                       G_IO_ERR | G_IO_HUP | G_IO_NVAL,
+                                       G_IO_IN | G_IO_ERR | G_IO_HUP | G_IO_NVAL,
                                        (GIOFunc) connection_death,
                                        new_conn);
                g_io_channel_unref (chan);
index 88625aa..6d32703 100644 (file)
@@ -61,9 +61,6 @@ soup_queue_error_cb (gboolean body_started, gpointer user_data)
 
        soup_connection_set_keep_alive (req->connection, FALSE);
 
-       req->priv->read_tag = 0;
-       req->priv->write_tag = 0;
-
        switch (req->status) {
        case SOUP_STATUS_IDLE:
        case SOUP_STATUS_QUEUED:
index c563756..7e07f75 100644 (file)
@@ -271,8 +271,11 @@ soup_socket_get_iochannel (SoupSocket* socket)
 {
        g_return_val_if_fail (socket != NULL, NULL);
 
-       if (socket->iochannel == NULL)
+       if (socket->iochannel == NULL) {
                socket->iochannel = g_io_channel_unix_new (socket->sockfd);
+               g_io_channel_set_encoding (socket->iochannel, NULL, NULL);
+               g_io_channel_set_buffered (socket->iochannel, FALSE);
+       }
 
        g_io_channel_ref (socket->iochannel);
 
index c5e9a81..77a7477 100644 (file)
@@ -447,16 +447,6 @@ soup_transfer_read_cb (GIOChannel   *iochannel,
        }
 
  PROCESS_READ:
-       /* 
-        * FIXME: Why are we getting a read_cb if there is no data to read? Yet
-        *        error_cb isn't being called and we get no error from
-        *        g_io_channel_read(). 
-        */
-       /*
-        * Update, Joe, 2/28/2003: Looks like we'll get this after a SIGPIPE.
-        * Instead of erroring out and probably messing with freed data,
-        * cancel out.
-        */
 
        if (r->header_len == 0 && total_read == 0)
                goto FINISH_READ;