diff options
author | Jeffrey Stedfast <fejj@novell.com> | 2004-11-16 03:39:21 +0800 |
---|---|---|
committer | Jeffrey Stedfast <fejj@src.gnome.org> | 2004-11-16 03:39:21 +0800 |
commit | 61be6fb593d2702c2d71f4e04224de551a99f9a5 (patch) | |
tree | f610635a643592fd50f987a8a9aaf6badf7ea804 | |
parent | 25cd94c2c4960a9a361c57c10bb3438cb42d422d (diff) | |
download | gsoc2013-evolution-61be6fb593d2702c2d71f4e04224de551a99f9a5.tar.gz gsoc2013-evolution-61be6fb593d2702c2d71f4e04224de551a99f9a5.tar.zst gsoc2013-evolution-61be6fb593d2702c2d71f4e04224de551a99f9a5.zip |
Moved the last tcp_stream unref to afetr the last fail-check so that we
2004-11-15 Jeffrey Stedfast <fejj@novell.com>
* providers/pop3/camel-pop3-store.c (connect_to_server): Moved the
last tcp_stream unref to afetr the last fail-check so that we
won't ever get a double-unref on something we only own one ref on.
svn path=/trunk/; revision=27925
-rw-r--r-- | camel/ChangeLog | 4 | ||||
-rw-r--r-- | camel/providers/pop3/camel-pop3-store.c | 4 |
2 files changed, 6 insertions, 2 deletions
diff --git a/camel/ChangeLog b/camel/ChangeLog index 76dcea3134..991e4d3ca1 100644 --- a/camel/ChangeLog +++ b/camel/ChangeLog @@ -1,5 +1,9 @@ 2004-11-15 Jeffrey Stedfast <fejj@novell.com> + * providers/pop3/camel-pop3-store.c (connect_to_server): Moved the + last tcp_stream unref to afetr the last fail-check so that we + won't ever get a double-unref on something we only own one ref on. + * providers/imap4/camel-imap4-stream.c (camel_imap4_stream_line): Fix bug #69408 by filling our input buffer if inptr == inend. diff --git a/camel/providers/pop3/camel-pop3-store.c b/camel/providers/pop3/camel-pop3-store.c index 3fcfef3fb7..0edff243e8 100644 --- a/camel/providers/pop3/camel-pop3-store.c +++ b/camel/providers/pop3/camel-pop3-store.c @@ -236,8 +236,6 @@ connect_to_server (CamelService *service, struct addrinfo *ai, int ssl_mode, Cam /* Okay, now toggle SSL/TLS mode */ ret = camel_tcp_stream_ssl_enable_ssl (CAMEL_TCP_STREAM_SSL (tcp_stream)); - camel_object_unref (CAMEL_OBJECT (tcp_stream)); - if (ret == -1) { camel_exception_setv (ex, CAMEL_EXCEPTION_SYSTEM, _("Failed to connect to POP server %s in secure mode: %s"), @@ -245,6 +243,8 @@ connect_to_server (CamelService *service, struct addrinfo *ai, int ssl_mode, Cam goto stls_exception; } + camel_object_unref (tcp_stream); + /* rfc2595, section 4 states that after a successful STLS command, the client MUST discard prior CAPA responses */ camel_pop3_engine_reget_capabilities (store->engine); |