Changes in / [41ca004:881fd4e]
- Files:
-
- 3 deleted
- 27 edited
Legend:
- Unmodified
- Added
- Removed
-
bitlbee.c
r41ca004 r881fd4e 34 34 #include <errno.h> 35 35 36 static gboolean bitlbee_io_new_client( gpointer data, gint fd, b_input_condition condition);36 gboolean bitlbee_io_new_client( GIOChannel *source, GIOCondition condition, gpointer data ); 37 37 38 38 int bitlbee_daemon_init() … … 44 44 #endif 45 45 int i; 46 GIOChannel *ch; 46 47 FILE *fp; 47 48 … … 90 91 } 91 92 92 global.listen_watch_source_id = b_input_add( global.listen_socket, GAIM_INPUT_READ, bitlbee_io_new_client, NULL ); 93 ch = g_io_channel_unix_new( global.listen_socket ); 94 global.listen_watch_source_id = g_io_add_watch( ch, G_IO_IN, bitlbee_io_new_client, NULL ); 93 95 94 96 #ifndef _WIN32 … … 145 147 } 146 148 147 gboolean bitlbee_io_current_client_read( gpointer data, gint fd, b_input_condition cond)149 gboolean bitlbee_io_current_client_read( GIOChannel *source, GIOCondition condition, gpointer data ) 148 150 { 149 151 irc_t *irc = data; … … 151 153 int st; 152 154 155 if( condition & G_IO_ERR || condition & G_IO_HUP ) 156 { 157 irc_abort( irc, 1, "Read error" ); 158 return FALSE; 159 } 160 153 161 st = read( irc->fd, line, sizeof( line ) - 1 ); 154 162 if( st == 0 ) … … 186 194 if( !g_slist_find( irc_connection_list, irc ) ) 187 195 { 188 log_message( LOGLVL_WARNING, "Abnormal termination of connection with fd %d.", fd );196 log_message( LOGLVL_WARNING, "Abnormal termination of connection with fd %d.", irc->fd ); 189 197 return FALSE; 190 198 } … … 200 208 } 201 209 202 gboolean bitlbee_io_current_client_write( gpointer data, gint fd, b_input_condition cond)210 gboolean bitlbee_io_current_client_write( GIOChannel *source, GIOCondition condition, gpointer data ) 203 211 { 204 212 irc_t *irc = data; … … 207 215 208 216 if( irc->sendbuffer == NULL ) 209 return FALSE;217 return( FALSE ); 210 218 211 219 size = strlen( irc->sendbuffer ); … … 231 239 irc_free( irc ); 232 240 233 return FALSE;241 return( FALSE ); 234 242 } 235 243 else … … 239 247 irc->sendbuffer = temp; 240 248 241 return TRUE;242 } 243 } 244 245 static gboolean bitlbee_io_new_client( gpointer data, gint fd, b_input_condition condition)246 { 247 s ocklen_t size = sizeof( struct sockaddr_in );249 return( TRUE ); 250 } 251 } 252 253 gboolean bitlbee_io_new_client( GIOChannel *source, GIOCondition condition, gpointer data ) 254 { 255 size_t size = sizeof( struct sockaddr_in ); 248 256 struct sockaddr_in conn_info; 249 257 int new_socket = accept( global.listen_socket, (struct sockaddr *) &conn_info, &size ); … … 278 286 child->pid = client_pid; 279 287 child->ipc_fd = fds[0]; 280 child->ipc_inpa = b_input_add( child->ipc_fd, GAIM_INPUT_READ, ipc_master_read, child );288 child->ipc_inpa = gaim_input_add( child->ipc_fd, GAIM_INPUT_READ, ipc_master_read, child ); 281 289 child_list = g_slist_append( child_list, child ); 282 290 … … 293 301 /* Close the listening socket, we're a client. */ 294 302 close( global.listen_socket ); 295 b_event_remove( global.listen_watch_source_id );303 g_source_remove( global.listen_watch_source_id ); 296 304 297 305 /* Make the connection. */ … … 300 308 /* We can store the IPC fd there now. */ 301 309 global.listen_socket = fds[1]; 302 global.listen_watch_source_id = b_input_add( fds[1], GAIM_INPUT_READ, ipc_child_read, irc );310 global.listen_watch_source_id = gaim_input_add( fds[1], GAIM_INPUT_READ, ipc_child_read, irc ); 303 311 304 312 close( fds[0] ); … … 316 324 } 317 325 318 gboolean bitlbee_shutdown( gpointer data, gint fd, b_input_condition cond)326 void bitlbee_shutdown( gpointer data ) 319 327 { 320 328 /* Try to save data for all active connections (if desired). */ … … 323 331 324 332 /* We'll only reach this point when not running in inetd mode: */ 325 b_main_quit(); 326 327 return FALSE; 328 } 333 g_main_quit( global.loop ); 334 } -
bitlbee.h
r41ca004 r881fd4e 58 58 /* The following functions should not be used if we want to maintain Windows compatibility... */ 59 59 #undef free 60 #define free __PLEASE_USE_THE_GLIB_MEMORY_ALLOCATION_SYSTEM_ _60 #define free __PLEASE_USE_THE_GLIB_MEMORY_ALLOCATION_SYSTEM_INSTEAD__ 61 61 #undef malloc 62 #define malloc __PLEASE_USE_THE_GLIB_MEMORY_ALLOCATION_SYSTEM_ _62 #define malloc __PLEASE_USE_THE_GLIB_MEMORY_ALLOCATION_SYSTEM_INSTEAD__ 63 63 #undef calloc 64 #define calloc __PLEASE_USE_THE_GLIB_MEMORY_ALLOCATION_SYSTEM_ _64 #define calloc __PLEASE_USE_THE_GLIB_MEMORY_ALLOCATION_SYSTEM_INSTEAD__ 65 65 #undef realloc 66 #define realloc __PLEASE_USE_THE_GLIB_MEMORY_ALLOCATION_SYSTEM_ _66 #define realloc __PLEASE_USE_THE_GLIB_MEMORY_ALLOCATION_SYSTEM_INSTEAD__ 67 67 #undef strdup 68 #define strdup __PLEASE_USE_THE_GLIB_STRDUP_FUNCTIONS_SYSTEM_ _68 #define strdup __PLEASE_USE_THE_GLIB_STRDUP_FUNCTIONS_SYSTEM_INSTEAD__ 69 69 #undef strndup 70 #define strndup __PLEASE_USE_THE_GLIB_STRDUP_FUNCTIONS_SYSTEM_ _70 #define strndup __PLEASE_USE_THE_GLIB_STRDUP_FUNCTIONS_SYSTEM_INSTEAD__ 71 71 #undef snprintf 72 #define snprintf __PLEASE_USE_G_SNPRINTF_ _72 #define snprintf __PLEASE_USE_G_SNPRINTF_INSTEAD__ 73 73 #undef strcasecmp 74 #define strcasecmp __PLEASE_USE_G_STRCASECMP_ _74 #define strcasecmp __PLEASE_USE_G_STRCASECMP_INSTEAD__ 75 75 #undef strncasecmp 76 #define strncasecmp __PLEASE_USE_G_STRNCASECMP__ 77 78 /* And the following functions shouldn't be used anymore to keep compatibility 79 with other event handling libs than GLib. */ 80 #undef g_timeout_add 81 #define g_timeout_add __PLEASE_USE_B_TIMEOUT_ADD__ 82 #undef g_timeout_add_full 83 #define g_timeout_add_full __PLEASE_USE_B_TIMEOUT_ADD__ 84 #undef g_io_add_watch 85 #define g_io_add_watch __PLEASE_USE_B_INPUT_ADD__ 86 #undef g_io_add_watch_full 87 #define g_io_add_watch_full __PLEASE_USE_B_INPUT_ADD__ 88 #undef g_source_remove 89 #define g_source_remove __PLEASE_USE_B_EVENT_REMOVE__ 90 #undef g_source_remove_by_user_data 91 #define g_source_remove_by_user_data __PLEASE_USE_B_SOURCE_REMOVE_BY_USER_DATA__ 92 #undef g_main_run 93 #define g_main_run __PLEASE_USE_B_MAIN_RUN__ 94 #undef g_main_quit 95 #define g_main_quit __PLEASE_USE_B_MAIN_QUIT__ 76 #define strncasecmp __PLEASE_USE_G_STRNCASECMP_INSTEAD__ 96 77 97 78 #ifndef F_OK … … 131 112 #include "sock.h" 132 113 #include "util.h" 133 #include "proxy.h"134 114 135 115 typedef struct global { … … 141 121 GList *storage; /* The first backend in the list will be used for saving */ 142 122 char *helpfile; 123 GMainLoop *loop; 143 124 int restart; 144 125 } global_t; … … 147 128 int bitlbee_inetd_init( void ); 148 129 149 gboolean bitlbee_io_current_client_read( gpointer data, gint source, b_input_condition cond);150 gboolean bitlbee_io_current_client_write( gpointer data, gint source, b_input_condition cond);130 gboolean bitlbee_io_current_client_read( GIOChannel *source, GIOCondition condition, gpointer data ); 131 gboolean bitlbee_io_current_client_write( GIOChannel *source, GIOCondition condition, gpointer data ); 151 132 152 133 void root_command_string( irc_t *irc, user_t *u, char *command, int flags ); 153 134 void root_command( irc_t *irc, char *command[] ); 154 gboolean bitlbee_shutdown( gpointer data, gint fd, b_input_condition cond);135 void bitlbee_shutdown( gpointer data ); 155 136 156 137 extern global_t global; -
configure
r41ca004 r881fd4e 14 14 datadir='$prefix/share/bitlbee/' 15 15 config='/var/lib/bitlbee/' 16 plugindir='$prefix/lib/bitlbee/'17 includedir='$prefix/include/bitlbee/'18 libevent='/usr/'19 16 pidfile='/var/run/bitlbee.pid' 20 17 ipcsocket='/var/run/bitlbee' 18 plugindir='$prefix/lib/bitlbee' 21 19 pcdir='$prefix/lib/pkgconfig' 20 includedir='$prefix/include/bitlbee' 22 21 23 22 msn=1 … … 29 28 strip=1 30 29 ipv6=1 31 32 events=glib33 30 ssl=auto 34 31 … … 67 64 --ipv6=0/1 IPv6 socket support $ipv6 68 65 69 --events=... Event handler (glib, libevent) $events70 66 --ssl=... SSL library to use (gnutls, nss, openssl, bogus, auto) 71 67 $ssl … … 84 80 config=`eval echo "$config/" | sed 's/\/\{1,\}/\//g'` 85 81 plugindir=`eval echo "$plugindir/" | sed 's/\/\{1,\}/\//g'` 86 includedir=`eval echo "$includedir"/ | sed 's/\/\{1,\}/\//g'`87 libevent=`eval echo "$libevent"/ | sed 's/\/\{1,\}/\//g'`88 89 82 pidfile=`eval echo "$pidfile" | sed 's/\/\{1,\}/\//g'` 90 83 ipcsocket=`eval echo "$ipcsocket" | sed 's/\/\{1,\}/\//g'` 84 includedir=`eval echo "$includedir" | sed 's/\/\{1,\}/\//g'` 91 85 pcdir=`eval echo "$pcdir" | sed 's/\/\{1,\}/\//g'` 92 86 … … 189 183 :; 190 184 elif [ -r /usr/local/include/iconv.h ]; then 191 echo CFLAGS+=-I/usr/local/include >> Makefile.settings 185 echo CFLAGS+=-I/usr/local/include >> Makefile.settings; 192 186 else 193 187 echo 194 188 echo 'Warning: Could not find iconv.h, you might have to install it and/or modify' 195 echo 'Makefile.settings to tell where this file is.' 196 fi 197 198 199 if [ "$events" = "libevent" ]; then 200 if ! [ -e "${libevent}include/event.h" ]; then 201 echo 202 echo 'Warning: Could not find event.h, you might have to install it and/or specify' 203 echo 'its location using the --libevent= argument. (Example: If event.h is in' 204 echo '/usr/local/include and binaries are in /usr/local/lib: --libevent=/usr/local)' 205 fi 206 207 echo '#define EVENTS_LIBEVENT' >> config.h 208 cat <<EOF>>Makefile.settings 209 EFLAGS+=-levent -L${libevent}lib 210 CFLAGS+=-I${libevent}include 211 EOF 212 elif [ "$events" = "glib" ]; then 213 ## We already use glib anyway, so this is all we need (and in fact not even this, but just to be sure...): 214 echo '#define EVENTS_GLIB' >> config.h 215 else 216 echo 217 echo 'ERROR: Unknown event handler specified.' 218 exit 1 219 fi 220 echo 'EVENT_HANDLER=events_'$events'.o' >> Makefile.settings 189 echo 'Makefile.settings to tell where this file is.'; 190 fi 221 191 222 192 … … 452 422 fi 453 423 454 echo ' Using event handler: '$events; 455 echo ' Using SSL library: '$ssl; 424 if [ "$msn" = "1" ]; then 425 echo ' Using SSL library: '$ssl; 426 fi 456 427 457 428 #if [ "$flood" = "0" ]; then -
ipc.c
r41ca004 r881fd4e 60 60 ipc_to_children_str( "DIE\r\n" ); 61 61 62 bitlbee_shutdown( NULL , -1, 0);62 bitlbee_shutdown( NULL ); 63 63 } 64 64 … … 91 91 92 92 global.restart = -1; 93 bitlbee_shutdown( NULL , -1, 0);93 bitlbee_shutdown( NULL ); 94 94 } 95 95 … … 246 246 } 247 247 248 gboolean ipc_master_read( gpointer data, gint source, b_input_condition cond )248 void ipc_master_read( gpointer data, gint source, GaimInputCondition cond ) 249 249 { 250 250 char *buf, **cmd; … … 272 272 } 273 273 } 274 275 return TRUE; 276 } 277 278 gboolean ipc_child_read( gpointer data, gint source, b_input_condition cond ) 274 } 275 276 void ipc_child_read( gpointer data, gint source, GaimInputCondition cond ) 279 277 { 280 278 char *buf, **cmd; … … 288 286 else 289 287 { 290 b_event_remove( global.listen_watch_source_id );288 gaim_input_remove( global.listen_watch_source_id ); 291 289 close( global.listen_socket ); 292 290 293 291 global.listen_socket = -1; 294 292 } 295 296 return TRUE;297 293 } 298 294 … … 401 397 void ipc_master_free_one( struct bitlbee_child *c ) 402 398 { 403 b_event_remove( c->ipc_inpa );399 gaim_input_remove( c->ipc_inpa ); 404 400 closesocket( c->ipc_fd ); 405 401 … … 467 463 468 464 469 static gboolean new_ipc_client ( gpointer data, gint serversock, b_input_condition cond)465 static gboolean new_ipc_client (GIOChannel *gio, GIOCondition cond, gpointer data) 470 466 { 471 467 struct bitlbee_child *child = g_new0( struct bitlbee_child, 1 ); 472 473 child->ipc_fd = accept( serversock, NULL, 0 ); 474 475 if( child->ipc_fd == -1 ) 476 { 468 int serversock; 469 470 serversock = g_io_channel_unix_get_fd(gio); 471 472 child->ipc_fd = accept(serversock, NULL, 0); 473 474 if (child->ipc_fd == -1) { 477 475 log_message( LOGLVL_WARNING, "Unable to accept connection on UNIX domain socket: %s", strerror(errno) ); 478 476 return TRUE; 479 477 } 480 478 481 child->ipc_inpa = b_input_add( child->ipc_fd, GAIM_INPUT_READ, ipc_master_read, child );482 479 child->ipc_inpa = gaim_input_add( child->ipc_fd, GAIM_INPUT_READ, ipc_master_read, child ); 480 483 481 child_list = g_slist_append( child_list, child ); 484 482 485 483 return TRUE; 486 484 } … … 491 489 struct sockaddr_un un_addr; 492 490 int serversock; 491 GIOChannel *gio; 493 492 494 493 /* Clean up old socket files that were hanging around.. */ … … 518 517 } 519 518 520 b_input_add( serversock, GAIM_INPUT_READ, new_ipc_client, NULL ); 521 519 gio = g_io_channel_unix_new(serversock); 520 521 if (gio == NULL) { 522 log_message( LOGLVL_WARNING, "Unable to create IO channel for unix socket" ); 523 return 0; 524 } 525 526 g_io_add_watch(gio, G_IO_IN, new_ipc_client, NULL); 522 527 return 1; 523 528 } … … 558 563 return 0; 559 564 } 560 child->ipc_inpa = b_input_add( child->ipc_fd, GAIM_INPUT_READ, ipc_master_read, child );565 child->ipc_inpa = gaim_input_add( child->ipc_fd, GAIM_INPUT_READ, ipc_master_read, child ); 561 566 562 567 child_list = g_slist_append( child_list, child ); -
ipc.h
r41ca004 r881fd4e 40 40 41 41 42 gboolean ipc_master_read( gpointer data, gint source, b_input_condition cond );43 gboolean ipc_child_read( gpointer data, gint source, b_input_condition cond );42 void ipc_master_read( gpointer data, gint source, GaimInputCondition cond ); 43 void ipc_child_read( gpointer data, gint source, GaimInputCondition cond ); 44 44 45 45 void ipc_master_free_one( struct bitlbee_child *child ); -
irc.c
r41ca004 r881fd4e 29 29 #include "ipc.h" 30 30 31 static gboolean irc_userping( gpointer _irc , int fd, b_input_condition cond);31 static gboolean irc_userping( gpointer _irc ); 32 32 33 33 GSList *irc_connection_list = NULL; … … 54 54 55 55 irc->fd = fd; 56 sock_make_nonblocking( irc->fd ); 57 58 irc->r_watch_source_id = b_input_add( irc->fd, GAIM_INPUT_READ, bitlbee_io_current_client_read, irc ); 56 irc->io_channel = g_io_channel_unix_new( fd ); 57 #ifdef GLIB2 58 g_io_channel_set_encoding (irc->io_channel, NULL, NULL); 59 g_io_channel_set_buffered (irc->io_channel, FALSE); 60 g_io_channel_set_flags( irc->io_channel, G_IO_FLAG_NONBLOCK, NULL ); 61 #else 62 fcntl( irc->fd, F_SETFL, O_NONBLOCK); 63 #endif 64 irc->r_watch_source_id = g_io_add_watch( irc->io_channel, G_IO_IN | G_IO_ERR | G_IO_HUP, bitlbee_io_current_client_read, irc ); 59 65 60 66 irc->status = USTATUS_OFFLINE; … … 114 120 115 121 if( global.conf->ping_interval > 0 && global.conf->ping_timeout > 0 ) 116 irc->ping_source_id = b_timeout_add( global.conf->ping_interval * 1000, irc_userping, irc );122 irc->ping_source_id = g_timeout_add( global.conf->ping_interval * 1000, irc_userping, irc ); 117 123 118 124 irc_write( irc, ":%s NOTICE AUTH :%s", irc->myhost, "BitlBee-IRCd initialized, please go on" ); … … 184 190 bitlbee_.._write doesn't do it first. */ 185 191 186 b_event_remove( irc->r_watch_source_id );187 irc->r_watch_source_id = b_timeout_add( 1000, (b_event_handler) irc_free, irc);192 g_source_remove( irc->r_watch_source_id ); 193 irc->r_watch_source_id = g_timeout_add_full( G_PRIORITY_HIGH, 1000, (GSourceFunc) irc_free, irc, NULL ); 188 194 } 189 195 else … … 218 224 219 225 if( irc->ping_source_id > 0 ) 220 b_event_remove( irc->ping_source_id );221 b_event_remove( irc->r_watch_source_id );226 g_source_remove( irc->ping_source_id ); 227 g_source_remove( irc->r_watch_source_id ); 222 228 if( irc->w_watch_source_id > 0 ) 223 b_event_remove( irc->w_watch_source_id ); 224 229 g_source_remove( irc->w_watch_source_id ); 230 231 g_io_channel_unref( irc->io_channel ); 225 232 irc_connection_list = g_slist_remove( irc_connection_list, irc ); 226 233 … … 272 279 if(user->host!=user->nick) g_free(user->host); 273 280 if(user->realname!=user->nick) g_free(user->realname); 274 b_event_remove(user->sendbuf_timer);281 gaim_input_remove(user->sendbuf_timer); 275 282 276 283 usertmp = user; … … 322 329 323 330 if( global.conf->runmode == RUNMODE_INETD || global.conf->runmode == RUNMODE_FORKDAEMON ) 324 b_main_quit();331 g_main_quit( global.loop ); 325 332 } 326 333 … … 576 583 char line[IRC_MAX_LINE+1], *cs; 577 584 578 /* Don't try to write anything new anymore when shutting down. */ 579 if( irc->status == USTATUS_SHUTDOWN ) 585 if( irc->quit ) 580 586 return; 581 587 … … 594 600 strcat( line, "\r\n" ); 595 601 596 if( irc->sendbuffer != NULL ) 597 { 602 if( irc->sendbuffer != NULL ) { 598 603 size = strlen( irc->sendbuffer ) + strlen( line ); 599 604 irc->sendbuffer = g_renew ( char, irc->sendbuffer, size + 1 ); 600 605 strcpy( ( irc->sendbuffer + strlen( irc->sendbuffer ) ), line ); 601 606 } 602 else 603 { 604 irc->sendbuffer = g_strdup(line); 605 } 607 else 608 irc->sendbuffer = g_strdup(line); 606 609 607 610 if( irc->w_watch_source_id == 0 ) 608 611 { 609 /* If the buffer is empty we can probably write, so call the write event handler 610 immediately. If it returns TRUE, it should be called again, so add the event to 611 the queue. If it's FALSE, we emptied the buffer and saved ourselves some work 612 in the event queue. */ 613 if( bitlbee_io_current_client_write( irc, irc->fd, GAIM_INPUT_WRITE ) ) 614 irc->w_watch_source_id = b_input_add( irc->fd, GAIM_INPUT_WRITE, bitlbee_io_current_client_write, irc ); 612 irc->w_watch_source_id = g_io_add_watch( irc->io_channel, G_IO_OUT, bitlbee_io_current_client_write, irc ); 615 613 } 616 614 … … 638 636 if( now ) 639 637 { 640 bitlbee_io_current_client_write( irc , irc->fd, GAIM_INPUT_WRITE);638 bitlbee_io_current_client_write( irc->io_channel, G_IO_OUT, irc ); 641 639 } 642 640 temp = temp->next; … … 1019 1017 } 1020 1018 1021 static gboolean buddy_send_handler_delayed( gpointer data, gint fd, b_input_condition cond)1019 gboolean buddy_send_handler_delayed( gpointer data ) 1022 1020 { 1023 1021 user_t *u = data; … … 1032 1030 u->sendbuf_flags = 0; 1033 1031 1034 return FALSE;1032 return( FALSE ); 1035 1033 } 1036 1034 … … 1046 1044 { 1047 1045 //Flush the buffer 1048 b_event_remove( u->sendbuf_timer );1049 buddy_send_handler_delayed( u , -1, 0);1046 g_source_remove( u->sendbuf_timer ); 1047 buddy_send_handler_delayed( u ); 1050 1048 } 1051 1049 … … 1071 1069 1072 1070 if( u->sendbuf_timer > 0 ) 1073 b_event_remove( u->sendbuf_timer );1074 u->sendbuf_timer = b_timeout_add( delay, buddy_send_handler_delayed, u );1071 g_source_remove( u->sendbuf_timer ); 1072 u->sendbuf_timer = g_timeout_add( delay, buddy_send_handler_delayed, u ); 1075 1073 } 1076 1074 else … … 1156 1154 pongs from the user. When not connected yet, we don't ping but drop the 1157 1155 connection when the user fails to connect in IRC_LOGIN_TIMEOUT secs. */ 1158 static gboolean irc_userping( gpointer _irc , gint fd, b_input_condition cond)1156 static gboolean irc_userping( gpointer _irc ) 1159 1157 { 1160 1158 irc_t *irc = _irc; -
irc.h
r41ca004 r881fd4e 61 61 char *sendbuffer; 62 62 char *readbuffer; 63 int quit; 63 64 64 65 int sentbytes; … … 92 93 struct set *set; 93 94 95 GIOChannel *io_channel; 94 96 gint r_watch_source_id; 95 97 gint w_watch_source_id; -
protocols/Makefile
r41ca004 r881fd4e 10 10 11 11 # [SH] Program variables 12 objects = $(EVENT_HANDLER)http_client.o md5.o nogaim.o proxy.o sha.o $(SSL_CLIENT)12 objects = http_client.o md5.o nogaim.o proxy.o sha.o $(SSL_CLIENT) 13 13 14 14 # [SH] The next two lines should contain the directory name (in $(subdirs)) -
protocols/http_client.c
r41ca004 r881fd4e 32 32 33 33 34 static gboolean http_connected( gpointer data, int source, b_input_condition cond );35 static gboolean http_ssl_connected( gpointer data, void *source, b_input_condition cond );36 static gboolean http_incoming_data( gpointer data, int source, b_input_condition cond );34 static void http_connected( gpointer data, int source, GaimInputCondition cond ); 35 static void http_ssl_connected( gpointer data, void *source, GaimInputCondition cond ); 36 static void http_incoming_data( gpointer data, int source, GaimInputCondition cond ); 37 37 38 38 … … 104 104 /* This one is actually pretty simple... Might get more calls if we can't write 105 105 the whole request at once. */ 106 static gboolean http_connected( gpointer data, int source, b_input_condition cond )106 static void http_connected( gpointer data, int source, GaimInputCondition cond ) 107 107 { 108 108 struct http_request *req = data; … … 113 113 114 114 if( req->inpa > 0 ) 115 b_event_remove( req->inpa );115 gaim_input_remove( req->inpa ); 116 116 117 117 sock_make_nonblocking( req->fd ); … … 148 148 149 149 if( req->bytes_written < req->request_length ) 150 req->inpa = b_input_add( source,151 req->ssl ? ssl_getdirection( req->ssl ) : GAIM_INPUT_WRITE,152 http_connected, req );153 else 154 req->inpa = b_input_add( source, GAIM_INPUT_READ, http_incoming_data, req );155 156 return FALSE;150 req->inpa = gaim_input_add( source, 151 req->ssl ? ssl_getdirection( req->ssl ) : GAIM_INPUT_WRITE, 152 http_connected, req ); 153 else 154 req->inpa = gaim_input_add( source, GAIM_INPUT_READ, http_incoming_data, req ); 155 156 return; 157 157 158 158 error: … … 162 162 g_free( req ); 163 163 164 return FALSE;164 return; 165 165 } 166 166 167 static gboolean http_ssl_connected( gpointer data, void *source, b_input_condition cond )167 static void http_ssl_connected( gpointer data, void *source, GaimInputCondition cond ) 168 168 { 169 169 struct http_request *req = data; … … 177 177 } 178 178 179 static gboolean http_incoming_data( gpointer data, int source, b_input_condition cond )179 static void http_incoming_data( gpointer data, int source, GaimInputCondition cond ) 180 180 { 181 181 struct http_request *req = data; … … 186 186 187 187 if( req->inpa > 0 ) 188 b_event_remove( req->inpa );188 gaim_input_remove( req->inpa ); 189 189 190 190 if( req->ssl ) … … 233 233 234 234 /* There will be more! */ 235 req->inpa = b_input_add( req->fd,236 req->ssl ? ssl_getdirection( req->ssl ) : GAIM_INPUT_READ,237 http_incoming_data, req );238 239 return FALSE;235 req->inpa = gaim_input_add( req->fd, 236 req->ssl ? ssl_getdirection( req->ssl ) : GAIM_INPUT_READ, 237 http_incoming_data, req ); 238 239 return; 240 240 241 241 got_reply: … … 396 396 req->reply_headers = req->reply_body = NULL; 397 397 398 return FALSE;398 return; 399 399 } 400 400 … … 414 414 g_free( req->reply_headers ); 415 415 g_free( req ); 416 417 return FALSE;418 416 } -
protocols/jabber/jabber.c
r41ca004 r881fd4e 471 471 } 472 472 473 static gboolean jabber_callback(gpointer data, gint source, b_input_condition condition)473 static void jabber_callback(gpointer data, gint source, GaimInputCondition condition) 474 474 { 475 475 struct gaim_connection *gc = (struct gaim_connection *)data; … … 477 477 478 478 gjab_recv(jd->gjc); 479 480 return TRUE;481 479 } 482 480 … … 489 487 } 490 488 491 static gboolean gjab_connected(gpointer data, gint source, b_input_condition cond)489 static void gjab_connected(gpointer data, gint source, GaimInputCondition cond) 492 490 { 493 491 xmlnode x; … … 499 497 if (!g_slist_find(get_connections(), gc)) { 500 498 closesocket(source); 501 return FALSE;499 return; 502 500 } 503 501 … … 510 508 if (source == -1) { 511 509 STATE_EVT(JCONN_STATE_OFF) 512 return FALSE;510 return; 513 511 } 514 512 … … 532 530 533 531 gc = GJ_GC(gjc); 534 gc->inpa = b_input_add(gjc->fd, GAIM_INPUT_READ, jabber_callback, gc); 535 536 return FALSE; 537 } 538 539 static gboolean gjab_connected_ssl(gpointer data, void *source, b_input_condition cond) 532 gc->inpa = gaim_input_add(gjc->fd, GAIM_INPUT_READ, jabber_callback, gc); 533 } 534 535 static void gjab_connected_ssl(gpointer data, void *source, GaimInputCondition cond) 540 536 { 541 537 struct gaim_connection *gc = data; … … 548 544 if (source == NULL) { 549 545 STATE_EVT(JCONN_STATE_OFF) 550 return FALSE;546 return; 551 547 } 552 548 553 549 if (!g_slist_find(get_connections(), gc)) { 554 550 ssl_disconnect(source); 555 return FALSE;551 return; 556 552 } 557 553 558 returngjab_connected(data, gjc->fd, cond);554 gjab_connected(data, gjc->fd, cond); 559 555 } 560 556 … … 1547 1543 } 1548 1544 1549 static gboolean jabber_free(gpointer data , gint fd, b_input_condition cond)1545 static gboolean jabber_free(gpointer data) 1550 1546 { 1551 1547 struct jabber_data *jd = data; … … 1592 1588 } 1593 1589 if (gc->inpa) 1594 b_event_remove(gc->inpa);1590 gaim_input_remove(gc->inpa); 1595 1591 1596 1592 if(jd) { 1597 b_timeout_add(50, jabber_free, jd);1593 g_timeout_add(50, jabber_free, jd); 1598 1594 if(jd->gjc != NULL) 1599 1595 xmlnode_free(jd->gjc->current); -
protocols/msn/msn.h
r41ca004 r881fd4e 146 146 147 147 /* ns.c */ 148 gboolean msn_ns_connected( gpointer data, gint source, b_input_condition cond );148 void msn_ns_connected( gpointer data, gint source, GaimInputCondition cond ); 149 149 150 150 /* msn_util.c */ … … 173 173 void msn_sb_to_chat( struct msn_switchboard *sb ); 174 174 void msn_sb_destroy( struct msn_switchboard *sb ); 175 gboolean msn_sb_connected( gpointer data, gint source, b_input_condition cond );175 void msn_sb_connected( gpointer data, gint source, GaimInputCondition cond ); -
protocols/msn/ns.c
r41ca004 r881fd4e 30 30 #include "md5.h" 31 31 32 static gboolean msn_ns_callback( gpointer data, gint source, b_input_condition cond );32 static void msn_ns_callback( gpointer data, gint source, GaimInputCondition cond ); 33 33 static int msn_ns_command( gpointer data, char **cmd, int num_parts ); 34 34 static int msn_ns_message( gpointer data, char *msg, int msglen, char **cmd, int num_parts ); … … 36 36 static void msn_auth_got_passport_id( struct passport_reply *rep ); 37 37 38 gboolean msn_ns_connected( gpointer data, gint source, b_input_condition cond )38 void msn_ns_connected( gpointer data, gint source, GaimInputCondition cond ) 39 39 { 40 40 struct gaim_connection *gc = data; … … 43 43 44 44 if( !g_slist_find( msn_connections, gc ) ) 45 return FALSE;45 return; 46 46 47 47 if( source == -1 ) … … 49 49 hide_login_progress( gc, "Could not connect to server" ); 50 50 signoff( gc ); 51 return FALSE;51 return; 52 52 } 53 53 … … 75 75 if( msn_write( gc, s, strlen( s ) ) ) 76 76 { 77 gc->inpa = b_input_add( md->fd, GAIM_INPUT_READ, msn_ns_callback, gc );77 gc->inpa = gaim_input_add( md->fd, GAIM_INPUT_READ, msn_ns_callback, gc ); 78 78 set_login_progress( gc, 1, "Connected to server, waiting for reply" ); 79 79 } 80 81 return FALSE;82 80 } 83 81 84 static gboolean msn_ns_callback( gpointer data, gint source, b_input_condition cond )82 void msn_ns_callback( gpointer data, gint source, GaimInputCondition cond ) 85 83 { 86 84 struct gaim_connection *gc = data; … … 91 89 hide_login_progress( gc, "Error while reading from server" ); 92 90 signoff( gc ); 93 94 return FALSE; 95 } 96 else 97 return TRUE; 91 } 98 92 } 99 93 … … 136 130 if( num_parts == 6 && strcmp( cmd[2], "NS" ) == 0 ) 137 131 { 138 b_event_remove( gc->inpa );132 gaim_input_remove( gc->inpa ); 139 133 gc->inpa = 0; 140 134 closesocket( md->fd ); -
protocols/msn/sb.c
r41ca004 r881fd4e 30 30 #include "md5.h" 31 31 32 static gboolean msn_sb_callback( gpointer data, gint source, b_input_condition cond );32 static void msn_sb_callback( gpointer data, gint source, GaimInputCondition cond ); 33 33 static int msn_sb_command( gpointer data, char **cmd, int num_parts ); 34 34 static int msn_sb_message( gpointer data, char *msg, int msglen, char **cmd, int num_parts ); … … 237 237 } 238 238 239 if( sb->inp ) b_event_remove( sb->inp );239 if( sb->inp ) gaim_input_remove( sb->inp ); 240 240 closesocket( sb->fd ); 241 241 … … 245 245 } 246 246 247 gboolean msn_sb_connected( gpointer data, gint source, b_input_condition cond )247 void msn_sb_connected( gpointer data, gint source, GaimInputCondition cond ) 248 248 { 249 249 struct msn_switchboard *sb = data; … … 254 254 /* Are we still alive? */ 255 255 if( !g_slist_find( msn_switchboards, sb ) ) 256 return FALSE;256 return; 257 257 258 258 gc = sb->gc; … … 263 263 debug( "ERROR %d while connecting to switchboard server", 1 ); 264 264 msn_sb_destroy( sb ); 265 return FALSE;265 return; 266 266 } 267 267 … … 280 280 281 281 if( msn_sb_write( sb, buf, strlen( buf ) ) ) 282 sb->inp = b_input_add( sb->fd, GAIM_INPUT_READ, msn_sb_callback, sb );282 sb->inp = gaim_input_add( sb->fd, GAIM_INPUT_READ, msn_sb_callback, sb ); 283 283 else 284 284 debug( "ERROR %d while connecting to switchboard server", 2 ); 285 286 return FALSE; 287 } 288 289 static gboolean msn_sb_callback( gpointer data, gint source, b_input_condition cond ) 285 } 286 287 static void msn_sb_callback( gpointer data, gint source, GaimInputCondition cond ) 290 288 { 291 289 struct msn_switchboard *sb = data; … … 295 293 debug( "ERROR: Switchboard died" ); 296 294 msn_sb_destroy( sb ); 297 298 return FALSE; 299 } 300 else 301 return TRUE; 295 } 302 296 } 303 297 -
protocols/nogaim.c
r41ca004 r881fd4e 2 2 * BitlBee -- An IRC to other IM-networks gateway * 3 3 * * 4 * Copyright 2002-200 6Wilmer van der Gaast and others *4 * Copyright 2002-2004 Wilmer van der Gaast and others * 5 5 \********************************************************************/ 6 6 … … 13 13 * from scratch for BitlBee and doesn't contain any code from Gaim anymore 14 14 * (except for the function names). 15 * 16 * Copyright 2002-2006 Wilmer van der Gaast <wilmer@gaast.net> and others 15 17 */ 16 18 … … 248 250 * This fixes daemon mode breakage where IRC doesn't point to the currently active connection. 249 251 */ 250 gc->irc =user->irc;252 gc->irc=user->irc; 251 253 252 254 connections = g_slist_append( connections, gc ); … … 328 330 } 329 331 330 static gboolean send_keepalive( gpointer d , gint fd, b_input_condition cond)332 static gboolean send_keepalive( gpointer d ) 331 333 { 332 334 struct gaim_connection *gc = d; … … 352 354 serv_got_crap( gc, "Logged in" ); 353 355 354 gc->keepalive = b_timeout_add( 60000, send_keepalive, gc );356 gc->keepalive = g_timeout_add( 60000, send_keepalive, gc ); 355 357 gc->flags |= OPT_LOGGED_IN; 356 358 … … 360 362 } 361 363 362 gboolean auto_reconnect( gpointer data , gint fd, b_input_condition cond)364 gboolean auto_reconnect( gpointer data ) 363 365 { 364 366 account_t *a = data; … … 372 374 void cancel_auto_reconnect( account_t *a ) 373 375 { 374 /* while( b_event_remove_by_data( (gpointer) a ) ); */ 375 b_event_remove( a->reconnect ); 376 while( g_source_remove_by_user_data( (gpointer) a ) ); 376 377 a->reconnect = 0; 377 378 } … … 385 386 serv_got_crap( gc, "Signing off.." ); 386 387 387 b_event_remove( gc->keepalive );388 gaim_input_remove( gc->keepalive ); 388 389 gc->keepalive = 0; 389 390 gc->prpl->close( gc ); 390 b_event_remove( gc->inpa );391 gaim_input_remove( gc->inpa ); 391 392 392 393 while( u ) … … 415 416 { 416 417 int delay = set_getint( irc, "auto_reconnect_delay" ); 417 418 418 serv_got_crap( gc, "Reconnecting in %d seconds..", delay ); 419 a->reconnect = b_timeout_add( delay * 1000, auto_reconnect, a ); 419 420 a->reconnect = 1; 421 g_timeout_add( delay * 1000, auto_reconnect, a ); 420 422 } 421 423 -
protocols/nogaim.h
r41ca004 r881fd4e 201 201 char *set_eval_away_devoice( irc_t *irc, set_t *set, char *value ); 202 202 203 gboolean auto_reconnect( gpointer data , gint fd, b_input_condition cond);203 gboolean auto_reconnect( gpointer data ); 204 204 void cancel_auto_reconnect( struct account *a ); 205 205 -
protocols/oscar/oscar.c
r41ca004 r881fd4e 253 253 static int msgerrreasonlen = 25; 254 254 255 static gbooleanoscar_callback(gpointer data, gint source,256 b_input_condition condition) {255 static void oscar_callback(gpointer data, gint source, 256 GaimInputCondition condition) { 257 257 aim_conn_t *conn = (aim_conn_t *)data; 258 258 aim_session_t *sess = aim_conn_getsess(conn); … … 262 262 if (!gc) { 263 263 /* gc is null. we return, else we seg SIGSEG on next line. */ 264 return FALSE;264 return; 265 265 } 266 266 … … 268 268 /* oh boy. this is probably bad. i guess the only thing we 269 269 * can really do is return? */ 270 return FALSE;270 return; 271 271 } 272 272 … … 288 288 c->conn = NULL; 289 289 if (c->inpa > 0) 290 b_event_remove(c->inpa);290 gaim_input_remove(c->inpa); 291 291 c->inpa = 0; 292 292 c->fd = -1; … … 296 296 } else if (conn->type == AIM_CONN_TYPE_CHATNAV) { 297 297 if (odata->cnpa > 0) 298 b_event_remove(odata->cnpa);298 gaim_input_remove(odata->cnpa); 299 299 odata->cnpa = 0; 300 300 while (odata->create_rooms) { … … 310 310 } else if (conn->type == AIM_CONN_TYPE_AUTH) { 311 311 if (odata->paspa > 0) 312 b_event_remove(odata->paspa);312 gaim_input_remove(odata->paspa); 313 313 odata->paspa = 0; 314 314 aim_conn_kill(odata->sess, &conn); … … 317 317 } 318 318 } 319 } else { 320 /* WTF??? */ 321 return FALSE; 322 } 323 324 return TRUE; 325 } 326 327 static gboolean oscar_login_connect(gpointer data, gint source, b_input_condition cond) 319 } 320 } 321 322 static void oscar_login_connect(gpointer data, gint source, GaimInputCondition cond) 328 323 { 329 324 struct gaim_connection *gc = data; … … 334 329 if (!g_slist_find(get_connections(), gc)) { 335 330 closesocket(source); 336 return FALSE;331 return; 337 332 } 338 333 … … 344 339 hide_login_progress(gc, _("Couldn't connect to host")); 345 340 signoff(gc); 346 return FALSE;341 return; 347 342 } 348 343 349 344 aim_conn_completeconnect(sess, conn); 350 gc->inpa = b_input_add(conn->fd, GAIM_INPUT_READ,345 gc->inpa = gaim_input_add(conn->fd, GAIM_INPUT_READ, 351 346 oscar_callback, conn); 352 353 return FALSE;354 347 } 355 348 … … 419 412 struct chat_connection *n = odata->oscar_chats->data; 420 413 if (n->inpa > 0) 421 b_event_remove(n->inpa);414 gaim_input_remove(n->inpa); 422 415 g_free(n->name); 423 416 g_free(n->show); … … 438 431 g_free(odata->oldp); 439 432 if (gc->inpa > 0) 440 b_event_remove(gc->inpa);433 gaim_input_remove(gc->inpa); 441 434 if (odata->cnpa > 0) 442 b_event_remove(odata->cnpa);435 gaim_input_remove(odata->cnpa); 443 436 if (odata->paspa > 0) 444 b_event_remove(odata->paspa);437 gaim_input_remove(odata->paspa); 445 438 aim_session_kill(odata->sess); 446 439 g_free(odata->sess); … … 450 443 } 451 444 452 static gboolean oscar_bos_connect(gpointer data, gint source, b_input_condition cond) {445 static void oscar_bos_connect(gpointer data, gint source, GaimInputCondition cond) { 453 446 struct gaim_connection *gc = data; 454 447 struct oscar_data *odata; … … 458 451 if (!g_slist_find(get_connections(), gc)) { 459 452 closesocket(source); 460 return FALSE;453 return; 461 454 } 462 455 … … 468 461 hide_login_progress(gc, _("Could Not Connect")); 469 462 signoff(gc); 470 return FALSE;463 return; 471 464 } 472 465 473 466 aim_conn_completeconnect(sess, bosconn); 474 gc->inpa = b_input_add(bosconn->fd, GAIM_INPUT_READ,467 gc->inpa = gaim_input_add(bosconn->fd, GAIM_INPUT_READ, 475 468 oscar_callback, bosconn); 476 469 set_login_progress(gc, 4, _("Connection established, cookie sent")); 477 478 return FALSE;479 470 } 480 471 … … 579 570 } 580 571 aim_sendcookie(sess, bosconn, info->cookie); 581 b_event_remove(gc->inpa);572 gaim_input_remove(gc->inpa); 582 573 583 574 return 1; … … 594 585 }; 595 586 596 static gboolean damn_you(gpointer data, gint source, b_input_condition c)587 static void damn_you(gpointer data, gint source, GaimInputCondition c) 597 588 { 598 589 struct pieceofcrap *pos = data; … … 614 605 do_error_dialog(pos->gc, "Gaim was unable to get a valid hash for logging into AIM." 615 606 " You may be disconnected shortly.", "Login Error"); 616 b_event_remove(pos->inpa);607 gaim_input_remove(pos->inpa); 617 608 closesocket(pos->fd); 618 609 g_free(pos); 619 return FALSE;610 return; 620 611 } 621 612 /* [WvG] Wheeeee! Who needs error checking anyway? ;-) */ 622 613 read(pos->fd, m, 16); 623 614 m[16] = '\0'; 624 b_event_remove(pos->inpa);615 gaim_input_remove(pos->inpa); 625 616 closesocket(pos->fd); 626 617 aim_sendmemblock(od->sess, pos->conn, 0, 16, m, AIM_SENDMEMBLOCK_FLAG_ISHASH); 627 618 g_free(pos); 628 629 return FALSE; 630 } 631 632 static gboolean straight_to_hell(gpointer data, gint source, b_input_condition cond) { 619 } 620 621 static void straight_to_hell(gpointer data, gint source, GaimInputCondition cond) { 633 622 struct pieceofcrap *pos = data; 634 623 char buf[BUF_LONG]; … … 640 629 g_free(pos->modname); 641 630 g_free(pos); 642 return FALSE;631 return; 643 632 } 644 633 … … 649 638 if (pos->modname) 650 639 g_free(pos->modname); 651 pos->inpa = b_input_add(pos->fd, GAIM_INPUT_READ, damn_you, pos);652 return FALSE;640 pos->inpa = gaim_input_add(pos->fd, GAIM_INPUT_READ, damn_you, pos); 641 return; 653 642 } 654 643 … … 772 761 } 773 762 774 static gboolean oscar_chatnav_connect(gpointer data, gint source, b_input_condition cond) {763 static void oscar_chatnav_connect(gpointer data, gint source, GaimInputCondition cond) { 775 764 struct gaim_connection *gc = data; 776 765 struct oscar_data *odata; … … 780 769 if (!g_slist_find(get_connections(), gc)) { 781 770 closesocket(source); 782 return FALSE;771 return; 783 772 } 784 773 … … 789 778 if (source < 0) { 790 779 aim_conn_kill(sess, &tstconn); 791 return FALSE;780 return; 792 781 } 793 782 794 783 aim_conn_completeconnect(sess, tstconn); 795 odata->cnpa = b_input_add(tstconn->fd, GAIM_INPUT_READ,784 odata->cnpa = gaim_input_add(tstconn->fd, GAIM_INPUT_READ, 796 785 oscar_callback, tstconn); 797 798 return FALSE; 799 } 800 801 static gboolean oscar_auth_connect(gpointer data, gint source, b_input_condition cond) 786 } 787 788 static void oscar_auth_connect(gpointer data, gint source, GaimInputCondition cond) 802 789 { 803 790 struct gaim_connection *gc = data; … … 808 795 if (!g_slist_find(get_connections(), gc)) { 809 796 closesocket(source); 810 return FALSE;797 return; 811 798 } 812 799 … … 817 804 if (source < 0) { 818 805 aim_conn_kill(sess, &tstconn); 819 return FALSE;806 return; 820 807 } 821 808 822 809 aim_conn_completeconnect(sess, tstconn); 823 odata->paspa = b_input_add(tstconn->fd, GAIM_INPUT_READ,810 odata->paspa = gaim_input_add(tstconn->fd, GAIM_INPUT_READ, 824 811 oscar_callback, tstconn); 825 826 return FALSE; 827 } 828 829 static gboolean oscar_chat_connect(gpointer data, gint source, b_input_condition cond) 812 } 813 814 static void oscar_chat_connect(gpointer data, gint source, GaimInputCondition cond) 830 815 { 831 816 struct chat_connection *ccon = data; … … 840 825 g_free(ccon->name); 841 826 g_free(ccon); 842 return FALSE;827 return; 843 828 } 844 829 … … 852 837 g_free(ccon->name); 853 838 g_free(ccon); 854 return FALSE;839 return; 855 840 } 856 841 857 842 aim_conn_completeconnect(sess, ccon->conn); 858 ccon->inpa = b_input_add(tstconn->fd,843 ccon->inpa = gaim_input_add(tstconn->fd, 859 844 GAIM_INPUT_READ, 860 845 oscar_callback, tstconn); 861 846 odata->oscar_chats = g_slist_append(odata->oscar_chats, ccon); 862 863 return FALSE;864 847 } 865 848 … … 2575 2558 od->oscar_chats = g_slist_remove(od->oscar_chats, cc); 2576 2559 if (cc->inpa > 0) 2577 b_event_remove(cc->inpa);2560 gaim_input_remove(cc->inpa); 2578 2561 aim_conn_kill(od->sess, &cc->conn); 2579 2562 g_free(cc->name); -
protocols/proxy.c
r41ca004 r881fd4e 21 21 */ 22 22 23 /* this is a little piece of code to handle proxy connection */ 24 /* it is intended to : 1st handle http proxy, using the CONNECT command 25 , 2nd provide an easy way to add socks support */ 26 23 27 #define BITLBEE_CORE 24 28 #include <stdio.h> … … 42 46 #include "proxy.h" 43 47 48 #define GAIM_READ_COND (G_IO_IN | G_IO_HUP | G_IO_ERR) 49 #define GAIM_WRITE_COND (G_IO_OUT | G_IO_HUP | G_IO_ERR | G_IO_NVAL) 50 #define GAIM_ERR_COND (G_IO_HUP | G_IO_ERR | G_IO_NVAL) 51 44 52 char proxyhost[128] = ""; 45 53 int proxyport = 0; … … 49 57 50 58 struct PHB { 51 b_event_handlerfunc, proxy_func;59 GaimInputFunction func, proxy_func; 52 60 gpointer data, proxy_data; 53 61 char *host; … … 56 64 gint inpa; 57 65 }; 66 67 typedef struct _GaimIOClosure { 68 GaimInputFunction function; 69 guint result; 70 gpointer data; 71 } GaimIOClosure; 58 72 59 73 … … 78 92 } 79 93 80 static gboolean gaim_io_connected(gpointer data, gint source, b_input_condition cond) 94 static void gaim_io_destroy(gpointer data) 95 { 96 g_free(data); 97 } 98 99 static gboolean gaim_io_invoke(GIOChannel *source, GIOCondition condition, gpointer data) 100 { 101 GaimIOClosure *closure = data; 102 GaimInputCondition gaim_cond = 0; 103 104 if (condition & GAIM_READ_COND) 105 gaim_cond |= GAIM_INPUT_READ; 106 if (condition & GAIM_WRITE_COND) 107 gaim_cond |= GAIM_INPUT_WRITE; 108 109 closure->function(closure->data, g_io_channel_unix_get_fd(source), gaim_cond); 110 111 return TRUE; 112 } 113 114 static void gaim_io_connected(gpointer data, gint source, GaimInputCondition cond) 81 115 { 82 116 struct PHB *phb = data; … … 88 122 if (getsockopt(source, SOL_SOCKET, SO_ERROR, &error, &len) < 0) { 89 123 closesocket(source); 90 b_event_remove(phb->inpa);124 gaim_input_remove(phb->inpa); 91 125 if( phb->proxy_func ) 92 126 phb->proxy_func(phb->proxy_data, -1, GAIM_INPUT_READ); … … 95 129 g_free(phb); 96 130 } 97 return FALSE;131 return; 98 132 } 99 133 #endif 100 134 sock_make_blocking(source); 101 b_event_remove(phb->inpa);135 gaim_input_remove(phb->inpa); 102 136 if( phb->proxy_func ) 103 137 phb->proxy_func(phb->proxy_data, source, GAIM_INPUT_READ); … … 106 140 g_free(phb); 107 141 } 108 109 return FALSE;110 142 } 111 143 … … 126 158 127 159 sock_make_nonblocking(fd); 128 129 event_debug("proxy_connect_none( \"%s\", %d ) = %d\n", host, port, fd); 130 160 131 161 if (connect(fd, (struct sockaddr *)sin, sizeof(*sin)) < 0) { 132 162 if (sockerr_again()) { 133 phb->inpa = b_input_add(fd, GAIM_INPUT_WRITE, gaim_io_connected, phb);163 phb->inpa = gaim_input_add(fd, GAIM_INPUT_WRITE, gaim_io_connected, phb); 134 164 phb->fd = fd; 135 165 } else { … … 149 179 #define HTTP_GOODSTRING2 "HTTP/1.1 200 Connection established" 150 180 151 static gboolean http_canread(gpointer data, gint source, b_input_condition cond)181 static void http_canread(gpointer data, gint source, GaimInputCondition cond) 152 182 { 153 183 int nlc = 0; … … 156 186 char inputline[8192]; 157 187 158 b_event_remove(phb->inpa);188 gaim_input_remove(phb->inpa); 159 189 160 190 while ((pos < sizeof(inputline)-1) && (nlc != 2) && (read(source, &inputline[pos++], 1) == 1)) { … … 171 201 g_free(phb->host); 172 202 g_free(phb); 173 return FALSE;203 return; 174 204 } 175 205 … … 178 208 g_free(phb->host); 179 209 g_free(phb); 180 181 return FALSE; 182 } 183 184 static gboolean http_canwrite(gpointer data, gint source, b_input_condition cond) 210 return; 211 } 212 213 static void http_canwrite(gpointer data, gint source, GaimInputCondition cond) 185 214 { 186 215 char cmd[384]; … … 189 218 int error = ETIMEDOUT; 190 219 if (phb->inpa > 0) 191 b_event_remove(phb->inpa);220 gaim_input_remove(phb->inpa); 192 221 len = sizeof(error); 193 222 if (getsockopt(source, SOL_SOCKET, SO_ERROR, &error, &len) < 0) { … … 196 225 g_free(phb->host); 197 226 g_free(phb); 198 return FALSE;227 return; 199 228 } 200 229 sock_make_blocking(source); … … 207 236 g_free(phb->host); 208 237 g_free(phb); 209 return FALSE;238 return; 210 239 } 211 240 … … 222 251 g_free(phb->host); 223 252 g_free(phb); 224 return FALSE;253 return; 225 254 } 226 255 } … … 232 261 g_free(phb->host); 233 262 g_free(phb); 234 return FALSE; 235 } 236 237 phb->inpa = b_input_add(source, GAIM_INPUT_READ, http_canread, phb); 238 239 return FALSE; 263 return; 264 } 265 266 phb->inpa = gaim_input_add(source, GAIM_INPUT_READ, http_canread, phb); 240 267 } 241 268 … … 253 280 /* Connecting to SOCKS4 proxies */ 254 281 255 static gboolean s4_canread(gpointer data, gint source, b_input_condition cond)282 static void s4_canread(gpointer data, gint source, GaimInputCondition cond) 256 283 { 257 284 unsigned char packet[12]; 258 285 struct PHB *phb = data; 259 286 260 b_event_remove(phb->inpa);287 gaim_input_remove(phb->inpa); 261 288 262 289 memset(packet, 0, sizeof(packet)); … … 265 292 g_free(phb->host); 266 293 g_free(phb); 267 return FALSE;294 return; 268 295 } 269 296 … … 272 299 g_free(phb->host); 273 300 g_free(phb); 274 275 return FALSE; 276 } 277 278 static gboolean s4_canwrite(gpointer data, gint source, b_input_condition cond) 301 } 302 303 static void s4_canwrite(gpointer data, gint source, GaimInputCondition cond) 279 304 { 280 305 unsigned char packet[12]; … … 284 309 int error = ETIMEDOUT; 285 310 if (phb->inpa > 0) 286 b_event_remove(phb->inpa);311 gaim_input_remove(phb->inpa); 287 312 len = sizeof(error); 288 313 if (getsockopt(source, SOL_SOCKET, SO_ERROR, &error, &len) < 0) { … … 291 316 g_free(phb->host); 292 317 g_free(phb); 293 return FALSE;318 return; 294 319 } 295 320 sock_make_blocking(source); … … 301 326 g_free(phb->host); 302 327 g_free(phb); 303 return FALSE;328 return; 304 329 } 305 330 … … 318 343 g_free(phb->host); 319 344 g_free(phb); 320 return FALSE; 321 } 322 323 phb->inpa = b_input_add(source, GAIM_INPUT_READ, s4_canread, phb); 324 325 return FALSE; 345 return; 346 } 347 348 phb->inpa = gaim_input_add(source, GAIM_INPUT_READ, s4_canread, phb); 326 349 } 327 350 … … 339 362 /* Connecting to SOCKS5 proxies */ 340 363 341 static gboolean s5_canread_again(gpointer data, gint source, b_input_condition cond)364 static void s5_canread_again(gpointer data, gint source, GaimInputCondition cond) 342 365 { 343 366 unsigned char buf[512]; 344 367 struct PHB *phb = data; 345 368 346 b_event_remove(phb->inpa);369 gaim_input_remove(phb->inpa); 347 370 348 371 if (read(source, buf, 10) < 10) { … … 351 374 g_free(phb->host); 352 375 g_free(phb); 353 return FALSE;376 return; 354 377 } 355 378 if ((buf[0] != 0x05) || (buf[1] != 0x00)) { … … 358 381 g_free(phb->host); 359 382 g_free(phb); 360 return FALSE;383 return; 361 384 } 362 385 … … 364 387 g_free(phb->host); 365 388 g_free(phb); 366 367 return FALSE; 389 return; 368 390 } 369 391 … … 373 395 struct PHB *phb = data; 374 396 int hlen = strlen(phb->host); 375 397 376 398 buf[0] = 0x05; 377 399 buf[1] = 0x01; /* CONNECT */ … … 391 413 } 392 414 393 phb->inpa = b_input_add(source, GAIM_INPUT_READ, s5_canread_again, phb);394 } 395 396 static gboolean s5_readauth(gpointer data, gint source, b_input_condition cond)415 phb->inpa = gaim_input_add(source, GAIM_INPUT_READ, s5_canread_again, phb); 416 } 417 418 static void s5_readauth(gpointer data, gint source, GaimInputCondition cond) 397 419 { 398 420 unsigned char buf[512]; 399 421 struct PHB *phb = data; 400 422 401 b_event_remove(phb->inpa);423 gaim_input_remove(phb->inpa); 402 424 403 425 if (read(source, buf, 2) < 2) { … … 406 428 g_free(phb->host); 407 429 g_free(phb); 408 return FALSE;430 return; 409 431 } 410 432 … … 414 436 g_free(phb->host); 415 437 g_free(phb); 416 return FALSE;438 return; 417 439 } 418 440 419 441 s5_sendconnect(phb, source); 420 421 return FALSE; 422 } 423 424 static gboolean s5_canread(gpointer data, gint source, b_input_condition cond) 442 } 443 444 static void s5_canread(gpointer data, gint source, GaimInputCondition cond) 425 445 { 426 446 unsigned char buf[512]; 427 447 struct PHB *phb = data; 428 448 429 b_event_remove(phb->inpa);449 gaim_input_remove(phb->inpa); 430 450 431 451 if (read(source, buf, 2) < 2) { … … 434 454 g_free(phb->host); 435 455 g_free(phb); 436 return FALSE;456 return; 437 457 } 438 458 … … 442 462 g_free(phb->host); 443 463 g_free(phb); 444 return FALSE;464 return; 445 465 } 446 466 … … 457 477 g_free(phb->host); 458 478 g_free(phb); 459 return FALSE;479 return; 460 480 } 461 481 462 phb->inpa = b_input_add(source, GAIM_INPUT_READ, s5_readauth, phb);482 phb->inpa = gaim_input_add(source, GAIM_INPUT_READ, s5_readauth, phb); 463 483 } else { 464 484 s5_sendconnect(phb, source); 465 485 } 466 467 return FALSE; 468 } 469 470 static gboolean s5_canwrite(gpointer data, gint source, b_input_condition cond) 486 } 487 488 static void s5_canwrite(gpointer data, gint source, GaimInputCondition cond) 471 489 { 472 490 unsigned char buf[512]; … … 476 494 int error = ETIMEDOUT; 477 495 if (phb->inpa > 0) 478 b_event_remove(phb->inpa);496 gaim_input_remove(phb->inpa); 479 497 len = sizeof(error); 480 498 if (getsockopt(source, SOL_SOCKET, SO_ERROR, &error, &len) < 0) { … … 483 501 g_free(phb->host); 484 502 g_free(phb); 485 return FALSE;503 return; 486 504 } 487 505 sock_make_blocking(source); … … 505 523 g_free(phb->host); 506 524 g_free(phb); 507 return FALSE; 508 } 509 510 phb->inpa = b_input_add(source, GAIM_INPUT_READ, s5_canread, phb); 511 512 return FALSE; 525 return; 526 } 527 528 phb->inpa = gaim_input_add(source, GAIM_INPUT_READ, s5_canread, phb); 513 529 } 514 530 … … 526 542 /* Export functions */ 527 543 528 int proxy_connect(const char *host, int port, b_event_handler func, gpointer data) 544 gint gaim_input_add(gint source, GaimInputCondition condition, GaimInputFunction function, gpointer data) 545 { 546 GaimIOClosure *closure = g_new0(GaimIOClosure, 1); 547 GIOChannel *channel; 548 GIOCondition cond = 0; 549 550 closure->function = function; 551 closure->data = data; 552 553 if (condition & GAIM_INPUT_READ) 554 cond |= GAIM_READ_COND; 555 if (condition & GAIM_INPUT_WRITE) 556 cond |= GAIM_WRITE_COND; 557 558 channel = g_io_channel_unix_new(source); 559 closure->result = g_io_add_watch_full(channel, G_PRIORITY_DEFAULT, cond, 560 gaim_io_invoke, closure, gaim_io_destroy); 561 562 g_io_channel_unref(channel); 563 return closure->result; 564 } 565 566 void gaim_input_remove(gint tag) 567 { 568 if (tag > 0) 569 g_source_remove(tag); 570 } 571 572 int proxy_connect(const char *host, int port, GaimInputFunction func, gpointer data) 529 573 { 530 574 struct PHB *phb; -
protocols/proxy.h
r41ca004 r881fd4e 1 1 /* 2 * nogaim2 * gaim 3 3 * 4 4 * Copyright (C) 1998-1999, Mark Spencer <markster@marko.net> … … 36 36 #include <gmodule.h> 37 37 38 #include "events.h"39 40 38 #define PROXY_NONE 0 41 39 #define PROXY_HTTP 1 … … 49 47 extern char proxypass[128]; 50 48 51 G_MODULE_EXPORT int proxy_connect(const char *host, int port, b_event_handler func, gpointer data); 49 typedef enum { 50 GAIM_INPUT_READ = 1 << 0, 51 GAIM_INPUT_WRITE = 1 << 1 52 } GaimInputCondition; 53 typedef void (*GaimInputFunction)(gpointer, gint, GaimInputCondition); 54 55 G_MODULE_EXPORT gint gaim_input_add(int, GaimInputCondition, GaimInputFunction, gpointer); 56 G_MODULE_EXPORT void gaim_input_remove(gint); 57 58 G_MODULE_EXPORT int proxy_connect(const char *host, int port, GaimInputFunction func, gpointer data); 52 59 53 60 #endif /* _PROXY_H_ */ -
protocols/ssl_bogus.c
r41ca004 r881fd4e 52 52 } 53 53 54 b_input_condition ssl_getdirection( void *conn )54 GaimInputCondition ssl_getdirection( void *conn ) 55 55 { 56 56 return GAIM_INPUT_READ; -
protocols/ssl_client.h
r41ca004 r881fd4e 33 33 extern int ssl_errno; 34 34 35 typedef gboolean (*ssl_input_function)(gpointer, void*, b_input_condition);35 typedef void (*ssl_input_function)(gpointer, void*, GaimInputCondition); 36 36 37 37 G_MODULE_EXPORT void *ssl_connect( char *host, int port, ssl_input_function func, gpointer data ); … … 40 40 G_MODULE_EXPORT void ssl_disconnect( void *conn_ ); 41 41 G_MODULE_EXPORT int ssl_getfd( void *conn ); 42 G_MODULE_EXPORT b_input_condition ssl_getdirection( void *conn );42 G_MODULE_EXPORT GaimInputCondition ssl_getdirection( void *conn ); -
protocols/ssl_gnutls.c
r41ca004 r881fd4e 48 48 }; 49 49 50 static gboolean ssl_connected( gpointer data, gint source, b_input_condition cond );50 static void ssl_connected( gpointer data, gint source, GaimInputCondition cond ); 51 51 52 52 … … 81 81 } 82 82 83 static gboolean ssl_handshake( gpointer data, gint source, b_input_condition cond );84 85 static gboolean ssl_connected( gpointer data, gint source, b_input_condition cond )83 static void ssl_handshake( gpointer data, gint source, GaimInputCondition cond ); 84 85 static void ssl_connected( gpointer data, gint source, GaimInputCondition cond ) 86 86 { 87 87 struct scd *conn = data; … … 96 96 g_free( conn ); 97 97 98 return FALSE;98 return; 99 99 } 100 100 … … 102 102 gnutls_transport_set_ptr( conn->session, (gnutls_transport_ptr) conn->fd ); 103 103 104 returnssl_handshake( data, source, cond );105 } 106 107 static gboolean ssl_handshake( gpointer data, gint source, b_input_condition cond )104 ssl_handshake( data, source, cond ); 105 } 106 107 static void ssl_handshake( gpointer data, gint source, GaimInputCondition cond ) 108 108 { 109 109 struct scd *conn = data; 110 110 int st; 111 111 112 if( conn->inpa != -1 ) 113 { 114 gaim_input_remove( conn->inpa ); 115 conn->inpa = -1; 116 } 117 112 118 if( ( st = gnutls_handshake( conn->session ) ) < 0 ) 113 119 { 114 120 if( st == GNUTLS_E_AGAIN || st == GNUTLS_E_INTERRUPTED ) 115 121 { 116 conn->inpa = b_input_add( conn->fd, ssl_getdirection( conn ),117 ssl_handshake, data );122 conn->inpa = gaim_input_add( conn->fd, ssl_getdirection( conn ), 123 ssl_handshake, data ); 118 124 } 119 125 else … … 136 142 conn->func( conn->data, conn, cond ); 137 143 } 138 139 return FALSE;140 144 } 141 145 … … 183 187 184 188 if( conn->inpa != -1 ) 185 b_event_remove( conn->inpa );189 gaim_input_remove( conn->inpa ); 186 190 187 191 if( conn->established ) … … 200 204 } 201 205 202 b_input_condition ssl_getdirection( void *conn )206 GaimInputCondition ssl_getdirection( void *conn ) 203 207 { 204 208 return( gnutls_record_get_direction( ((struct scd*)conn)->session ) ? -
protocols/ssl_nss.c
r41ca004 r881fd4e 52 52 }; 53 53 54 static gboolean ssl_connected( gpointer data, gint source, b_input_condition cond );54 static void ssl_connected( gpointer data, gint source, GaimInputCondition cond ); 55 55 56 56 … … 116 116 } 117 117 118 static gboolean ssl_connected( gpointer data, gint source, b_input_condition cond )118 static void ssl_connected( gpointer data, gint source, GaimInputCondition cond ) 119 119 { 120 120 struct scd *conn = data; … … 140 140 conn->established = TRUE; 141 141 conn->func( conn->data, conn, cond ); 142 return FALSE;142 return; 143 143 144 144 ssl_connected_failure: … … 149 149 if( source >= 0 ) closesocket( source ); 150 150 g_free( conn ); 151 152 return FALSE;153 151 } 154 152 … … 184 182 } 185 183 186 b_input_condition ssl_getdirection( void *conn )184 GaimInputCondition ssl_getdirection( void *conn ) 187 185 { 188 186 /* Just in case someone calls us, let's return the most likely case: */ -
protocols/ssl_openssl.c
r41ca004 r881fd4e 52 52 }; 53 53 54 static gboolean ssl_connected( gpointer data, gint source, b_input_condition cond ); 54 static void ssl_connected( gpointer data, gint source, GaimInputCondition cond ); 55 55 56 56 57 … … 94 95 } 95 96 96 static gboolean ssl_handshake( gpointer data, gint source, b_input_condition cond );97 98 static gboolean ssl_connected( gpointer data, gint source, b_input_condition cond )97 static void ssl_handshake( gpointer data, gint source, GaimInputCondition cond ); 98 99 static void ssl_connected( gpointer data, gint source, GaimInputCondition cond ) 99 100 { 100 101 struct scd *conn = data; … … 103 104 return ssl_handshake( data, -1, cond ); 104 105 105 /* We can do at least the handshake with non-blocking I/O*/106 /* Make it non-blocking at least during the handshake... */ 106 107 sock_make_nonblocking( conn->fd ); 107 108 SSL_set_fd( conn->ssl, conn->fd ); … … 110 111 } 111 112 112 static gboolean ssl_handshake( gpointer data, gint source, b_input_condition cond )113 static void ssl_handshake( gpointer data, gint source, GaimInputCondition cond ) 113 114 { 114 115 struct scd *conn = data; 115 116 int st; 117 118 if( conn->inpa != -1 ) 119 { 120 gaim_input_remove( conn->inpa ); 121 conn->inpa = -1; 122 } 116 123 117 124 if( ( st = SSL_connect( conn->ssl ) ) < 0 ) … … 121 128 goto ssl_connected_failure; 122 129 123 conn->inpa = b_input_add( conn->fd, ssl_getdirection( conn ), ssl_handshake, data );124 return FALSE;130 conn->inpa = gaim_input_add( conn->fd, ssl_getdirection( conn ), ssl_handshake, data ); 131 return; 125 132 } 126 133 … … 128 135 sock_make_blocking( conn->fd ); /* For now... */ 129 136 conn->func( conn->data, conn, cond ); 130 return FALSE;137 return; 131 138 132 139 ssl_connected_failure: … … 144 151 if( source >= 0 ) closesocket( source ); 145 152 g_free( conn ); 146 147 return FALSE;148 153 } 149 154 … … 199 204 200 205 if( conn->inpa != -1 ) 201 b_event_remove( conn->inpa );206 gaim_input_remove( conn->inpa ); 202 207 203 208 if( conn->established ) … … 216 221 } 217 222 218 b_input_condition ssl_getdirection( void *conn )223 GaimInputCondition ssl_getdirection( void *conn ) 219 224 { 220 225 return( ((struct scd*)conn)->lasterr == SSL_ERROR_WANT_WRITE ? GAIM_INPUT_WRITE : GAIM_INPUT_READ ); -
protocols/yahoo/yahoo.c
r41ca004 r881fd4e 443 443 }; 444 444 445 void byahoo_connect_callback( gpointer data, gint source, b_input_condition cond )445 void byahoo_connect_callback( gpointer data, gint source, GaimInputCondition cond ) 446 446 { 447 447 struct byahoo_connect_callback_data *d = data; … … 465 465 }; 466 466 467 gboolean byahoo_read_ready_callback( gpointer data, gint source, b_input_condition cond )467 void byahoo_read_ready_callback( gpointer data, gint source, GaimInputCondition cond ) 468 468 { 469 469 struct byahoo_read_ready_data *d = data; 470 470 471 471 if( !byahoo_get_gc_by_id( d->id ) ) 472 { 472 473 /* WTF doesn't libyahoo clean this up? */ 473 return FALSE; 474 ext_yahoo_remove_handler( d->id, d->tag ); 475 return; 476 } 474 477 475 478 yahoo_read_ready( d->id, d->fd, d->data ); 476 477 return TRUE;478 479 } 479 480 … … 486 487 }; 487 488 488 gboolean byahoo_write_ready_callback( gpointer data, gint source, b_input_condition cond )489 void byahoo_write_ready_callback( gpointer data, gint source, GaimInputCondition cond ) 489 490 { 490 491 struct byahoo_write_ready_data *d = data; 491 492 492 493 if( !byahoo_get_gc_by_id( d->id ) ) 494 { 493 495 /* WTF doesn't libyahoo clean this up? */ 494 return FALSE; 496 ext_yahoo_remove_handler( d->id, d->tag ); 497 return; 498 } 495 499 496 500 yahoo_write_ready( d->id, d->fd, d->data ); 497 498 return FALSE;499 501 } 500 502 … … 685 687 686 688 inp->d = d; 687 d->tag = inp->h = b_input_add( fd, GAIM_INPUT_READ, (b_event_handler) byahoo_read_ready_callback, (gpointer) d );689 d->tag = inp->h = gaim_input_add( fd, GAIM_INPUT_READ, (GaimInputFunction) byahoo_read_ready_callback, (gpointer) d ); 688 690 } 689 691 else if( cond == YAHOO_INPUT_WRITE ) … … 696 698 697 699 inp->d = d; 698 d->tag = inp->h = b_input_add( fd, GAIM_INPUT_WRITE, (b_event_handler) byahoo_write_ready_callback, (gpointer) d );700 d->tag = inp->h = gaim_input_add( fd, GAIM_INPUT_WRITE, (GaimInputFunction) byahoo_write_ready_callback, (gpointer) d ); 699 701 } 700 702 else … … 727 729 } 728 730 729 b_event_remove( tag );731 gaim_input_remove( tag ); 730 732 } 731 733 … … 736 738 737 739 d = g_new0( struct byahoo_connect_callback_data, 1 ); 738 if( ( fd = proxy_connect( host, port, ( b_event_handler) byahoo_connect_callback, (gpointer) d ) ) < 0 )740 if( ( fd = proxy_connect( host, port, (GaimInputFunction) byahoo_connect_callback, (gpointer) d ) ) < 0 ) 739 741 { 740 742 g_free( d ); -
sock.h
r41ca004 r881fd4e 18 18 #define sock_make_blocking(fd) fcntl(fd, F_SETFL, 0) 19 19 #define sockerr_again() (errno == EINPROGRESS || errno == EINTR) 20 #ifndef EVENTS_LIBEVENT21 20 #define closesocket(a) close(a) 22 #endif23 21 #else 24 22 # include <winsock2.h> -
unix.c
r41ca004 r881fd4e 47 47 memset( &global, 0, sizeof( global_t ) ); 48 48 49 b_main_init();49 global.loop = g_main_new( FALSE ); 50 50 51 51 log_init(); … … 117 117 log_message( LOGLVL_WARNING, "Error opening helpfile %s.", HELP_FILE ); 118 118 119 b_main_run();119 g_main_run( global.loop ); 120 120 121 121 if( global.restart ) … … 165 165 166 166 log_message( LOGLVL_ERROR, "SIGTERM received, cleaning up process." ); 167 b_timeout_add( 1, (b_event_handler) bitlbee_shutdown, NULL );167 g_timeout_add_full( G_PRIORITY_LOW, 1, (GSourceFunc) bitlbee_shutdown, NULL, NULL ); 168 168 169 169 first = 0; -
user.c
r41ca004 r881fd4e 109 109 if( u->handle ) g_free( u->handle ); 110 110 if( u->sendbuf ) g_free( u->sendbuf ); 111 if( u->sendbuf_timer ) b_event_remove( u->sendbuf_timer );111 if( u->sendbuf_timer ) g_source_remove( u->sendbuf_timer ); 112 112 g_free( u ); 113 113
Note: See TracChangeset
for help on using the changeset viewer.