diff options
author | Holger Hans Peter Freyther <zecke@selfish.org> | 2010-08-07 02:26:47 +0800 |
---|---|---|
committer | Holger Hans Peter Freyther <zecke@selfish.org> | 2010-08-07 02:26:47 +0800 |
commit | 625853992819593d33a5f6fa874bd98943b342b3 (patch) | |
tree | ef10ec47f63e8d9563dac22aecd33b2a5a9d8ebc | |
parent | 71f4f355fadfbb2e32f143ae7bc9fd308bd0f195 (diff) |
msc: Use the msc_close_connection routine
Remove code duplication, the only difference is that the generic
callback pointer is not reset. But as we have lost the connection
we will go through the normnal connect again which will fix things.
-rw-r--r-- | src/msc_conn.c | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/src/msc_conn.c b/src/msc_conn.c index ad48490..c8ecb1d 100644 --- a/src/msc_conn.c +++ b/src/msc_conn.c @@ -273,14 +273,7 @@ static int msc_connection_connect(struct bsc_fd *fd, unsigned int what) return 0; error: - bsc_unregister_fd(fd); - close(fd->fd); - fd->fd = -1; - fd->cb = write_queue_bfd_cb; - fd->when = 0; - release_bsc_resources(bsc); - bsc_del_timer(&bsc->ping_timeout); - bsc_del_timer(&bsc->pong_timeout); + msc_close_connection(bsc); return -1; } |