diff options
author | Jeffrey Stedfast <fejj@ximian.com> | 2001-01-16 08:54:18 +0800 |
---|---|---|
committer | Jeffrey Stedfast <fejj@src.gnome.org> | 2001-01-16 08:54:18 +0800 |
commit | d9b76e981fae89ad0da878cb8bb5b261a9988ddd (patch) | |
tree | 8119a880d3de3786fde249a088370b1dfc132daf /camel/camel-tcp-stream.c | |
parent | baffaa57693681c163723962445551c677f8f51b (diff) | |
download | gsoc2013-evolution-d9b76e981fae89ad0da878cb8bb5b261a9988ddd.tar gsoc2013-evolution-d9b76e981fae89ad0da878cb8bb5b261a9988ddd.tar.gz gsoc2013-evolution-d9b76e981fae89ad0da878cb8bb5b261a9988ddd.tar.bz2 gsoc2013-evolution-d9b76e981fae89ad0da878cb8bb5b261a9988ddd.tar.lz gsoc2013-evolution-d9b76e981fae89ad0da878cb8bb5b261a9988ddd.tar.xz gsoc2013-evolution-d9b76e981fae89ad0da878cb8bb5b261a9988ddd.tar.zst gsoc2013-evolution-d9b76e981fae89ad0da878cb8bb5b261a9988ddd.zip |
If the close() is successful, set the fd to -1.
2001-01-15 Jeffrey Stedfast <fejj@ximian.com>
* camel-stream-fs.c (stream_close): If the close() is successful,
set the fd to -1.
* camel-tcp-stream-raw.c: Removed the disconnect() method.
(stream_close): If the close() is successful, set the sockfd to
-1.
* camel-tcp-stream-ssl.c: Removed the disconnect() method.
(stream_close): If the close() is successful, set the sockfd to
NULL.
* camel-tcp-stream.c (camel_tcp_stream_disconnect): Removed,
easier to just use the close() method as it did the same thing
anyway.
svn path=/trunk/; revision=7522
Diffstat (limited to 'camel/camel-tcp-stream.c')
-rw-r--r-- | camel/camel-tcp-stream.c | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/camel/camel-tcp-stream.c b/camel/camel-tcp-stream.c index d335cc7393..6edd545a1f 100644 --- a/camel/camel-tcp-stream.c +++ b/camel/camel-tcp-stream.c @@ -31,7 +31,6 @@ static CamelStreamClass *parent_class = NULL; #define CTS_CLASS(so) CAMEL_TCP_STREAM_CLASS (CAMEL_OBJECT_GET_CLASS(so)) static int tcp_connect (CamelTcpStream *stream, struct hostent *host, int port); -static int tcp_disconnect (CamelTcpStream *stream); static int tcp_getsockopt (CamelTcpStream *stream, CamelSockOptData *data); static int tcp_setsockopt (CamelTcpStream *stream, const CamelSockOptData *data); @@ -45,7 +44,6 @@ camel_tcp_stream_class_init (CamelTcpStreamClass *camel_tcp_stream_class) /* tcp stream methods */ camel_tcp_stream_class->connect = tcp_connect; - camel_tcp_stream_class->disconnect = tcp_disconnect; camel_tcp_stream_class->getsockopt = tcp_getsockopt; camel_tcp_stream_class->setsockopt = tcp_setsockopt; } @@ -103,31 +101,6 @@ camel_tcp_stream_connect (CamelTcpStream *stream, struct hostent *host, int port static int -tcp_disconnect (CamelTcpStream *stream) -{ - g_warning ("CamelTcpStream::disconnect called on default implementation\n"); - return -1; -} - - -/** - * camel_tcp_stream_disconnect: - * @stream: tcp stream object - * - * Disconnect the tcp stream and properly close the socket. - * - * Return value: zero on success or -1 on fail. - **/ -int -camel_tcp_stream_disconnect (CamelTcpStream *stream) -{ - g_return_val_if_fail (CAMEL_IS_TCP_STREAM (stream), -1); - - return CTS_CLASS (stream)->disconnect (stream); -} - - -static int tcp_getsockopt (CamelTcpStream *stream, CamelSockOptData *data) { g_warning ("CamelTcpStream::getsockopt called on default implementation\n"); |