Changes in protocols/nogaim.c [90cd6c4:58adb7e]
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
protocols/nogaim.c
r90cd6c4 r58adb7e 98 98 void register_protocol (struct prpl *p) 99 99 { 100 int i; 101 gboolean refused = global.conf->protocols != NULL; 102 103 for (i = 0; global.conf->protocols && global.conf->protocols[i]; i++) 104 { 105 if (g_strcasecmp(p->name, global.conf->protocols[i]) == 0) 106 refused = FALSE; 107 } 108 109 if (refused) 110 log_message(LOGLVL_WARNING, "Protocol %s disabled\n", p->name); 111 else 112 protocols = g_list_append(protocols, p); 100 protocols = g_list_append(protocols, p); 113 101 } 114 102 … … 383 371 /* list.c */ 384 372 385 void imcb_add_buddy( struct im_connection *ic, c onst char *handle, constchar *group )373 void imcb_add_buddy( struct im_connection *ic, char *handle, char *group ) 386 374 { 387 375 user_t *u; … … 457 445 } 458 446 459 void imcb_rename_buddy( struct im_connection *ic, c onst char *handle, constchar *realname )447 void imcb_rename_buddy( struct im_connection *ic, char *handle, char *realname ) 460 448 { 461 449 user_t *u = user_findhandle( ic, handle ); 462 char *set;463 450 464 451 if( !u || !realname ) return; … … 473 460 imcb_log( ic, "User `%s' changed name to `%s'", u->nick, u->realname ); 474 461 } 475 476 set = set_getstr( &ic->acc->set, "nick_source" ); 477 if( strcmp( set, "handle" ) != 0 ) 478 { 479 char *name = g_strdup( realname ); 480 481 if( strcmp( set, "first_name" ) == 0 ) 482 { 483 int i; 484 for( i = 0; name[i] && !isspace( name[i] ); i ++ ) {} 485 name[i] = '\0'; 486 } 487 488 imcb_buddy_nick_hint( ic, handle, name ); 489 490 g_free( name ); 491 } 492 } 493 494 void imcb_remove_buddy( struct im_connection *ic, const char *handle, char *group ) 462 } 463 464 void imcb_remove_buddy( struct im_connection *ic, char *handle, char *group ) 495 465 { 496 466 user_t *u; … … 502 472 /* Mainly meant for ICQ (and now also for Jabber conferences) to allow IM 503 473 modules to suggest a nickname for a handle. */ 504 void imcb_buddy_nick_hint( struct im_connection *ic, c onst char *handle, constchar *nick )474 void imcb_buddy_nick_hint( struct im_connection *ic, char *handle, char *nick ) 505 475 { 506 476 user_t *u = user_findhandle( ic, handle ); … … 714 684 } 715 685 716 void imcb_buddy_msg( struct im_connection *ic, c onst char *handle, char *msg, uint32_t flags, time_t sent_at )686 void imcb_buddy_msg( struct im_connection *ic, char *handle, char *msg, uint32_t flags, time_t sent_at ) 717 687 { 718 688 irc_t *irc = ic->irc; … … 847 817 } 848 818 849 void imcb_chat_msg( struct groupchat *c, c onst char *who, char *msg, uint32_t flags, time_t sent_at )819 void imcb_chat_msg( struct groupchat *c, char *who, char *msg, uint32_t flags, time_t sent_at ) 850 820 { 851 821 struct im_connection *ic = c->ic; … … 919 889 /* buddy_chat.c */ 920 890 921 void imcb_chat_add_buddy( struct groupchat *b, c onst char *handle )891 void imcb_chat_add_buddy( struct groupchat *b, char *handle ) 922 892 { 923 893 user_t *u = user_findhandle( b->ic, handle ); … … 954 924 955 925 /* This function is one BIG hack... :-( EREWRITE */ 956 void imcb_chat_remove_buddy( struct groupchat *b, c onst char *handle, constchar *reason )926 void imcb_chat_remove_buddy( struct groupchat *b, char *handle, char *reason ) 957 927 { 958 928 user_t *u; … … 1103 1073 int imc_away_send_update( struct im_connection *ic ) 1104 1074 { 1105 char *away, *msg = NULL;1075 char *away, *msg; 1106 1076 1107 1077 away = set_getstr( &ic->acc->set, "away" ) ?
Note: See TracChangeset
for help on using the changeset viewer.