# HG changeset patch # User hallski # Date 1068553365 0 # Node ID eee846c76348353ca148625819066092b096bea8 # Parent d9a0e2c2a9aa7cba7cac7c157ef963603f22f073 2003-11-11 Mikael Hallendal * Makefile.am: - Added README.WIN32 so it will be distributed next release. * loudmouth/lm-connection.c: (connection_do_close): Remove the incoming source. Reported and fix proposed by Christopher G. Abiad (lm_connection_authenticate_and_block): - Set error message on auth failed (should be more explicit). Fixes problem when you try to read the error message on fail. diff -r d9a0e2c2a9aa -r eee846c76348 ChangeLog --- a/ChangeLog Tue Nov 11 12:21:53 2003 +0000 +++ b/ChangeLog Tue Nov 11 12:22:45 2003 +0000 @@ -1,3 +1,14 @@ +2003-11-11 Mikael Hallendal + + * Makefile.am: + - Added README.WIN32 so it will be distributed next release. + * loudmouth/lm-connection.c: + (connection_do_close): Remove the incoming source. Reported and fix + proposed by Christopher G. Abiad + (lm_connection_authenticate_and_block): + - Set error message on auth failed (should be more explicit). Fixes + problem when you try to read the error message on fail. + 2003-11-11 Mikael Hallendal * Makefile.am: diff -r d9a0e2c2a9aa -r eee846c76348 loudmouth/lm-connection.c --- a/loudmouth/lm-connection.c Tue Nov 11 12:21:53 2003 +0000 +++ b/loudmouth/lm-connection.c Tue Nov 11 12:22:45 2003 +0000 @@ -402,7 +402,10 @@ g_io_channel_unref (connection->io_channel); connection->io_channel = NULL; - } + } + + g_source_remove (g_source_get_id (connection->incoming_source)); + g_source_unref (connection->incoming_source); if (!connection->is_open) { return; @@ -484,7 +487,8 @@ } buf[bytes_read] = '\0'; - g_log (LM_LOG_DOMAIN, LM_LOG_LEVEL_NET, "\nRECV:\n"); + g_log (LM_LOG_DOMAIN, LM_LOG_LEVEL_NET, "\nRECV [%d]:\n", + bytes_read); g_log (LM_LOG_DOMAIN, LM_LOG_LEVEL_NET, "-----------------------------------\n"); g_log (LM_LOG_DOMAIN, LM_LOG_LEVEL_NET, "'%s'\n", buf); @@ -1213,6 +1217,10 @@ return TRUE; break; case LM_MESSAGE_SUB_TYPE_ERROR: + g_set_error (error, + LM_ERROR, + LM_ERROR_AUTH_FAILED, + "Authentication failed"); return FALSE; break; default: