- Timestamp:
- 2007-12-18T23:59:35Z (17 years ago)
- Branches:
- master
- Children:
- 2379566
- Parents:
- dc0ba9c
- Location:
- protocols
- Files:
-
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
protocols/jabber/conference.c
rdc0ba9c reded1f7 174 174 175 175 return 1; 176 } 177 178 void jabber_chat_invite( struct groupchat *c, char *who, char *message ) 179 { 180 struct xt_node *node; 181 struct im_connection *ic = c->ic; 182 struct jabber_chat *jc = c->data; 183 184 node = xt_new_node( "reason", message, NULL ); 185 186 node = xt_new_node( "invite", NULL, node ); 187 xt_add_attr( node, "to", who ); 188 189 node = xt_new_node( "x", NULL, node ); 190 xt_add_attr( node, "xmlns", XMLNS_MUC_USER ); 191 192 node = jabber_make_packet( "message", NULL, jc->name, node ); 193 194 jabber_write_packet( ic, node ); 195 196 xt_free_node( node ); 176 197 } 177 198 -
protocols/jabber/io.c
rdc0ba9c reded1f7 120 120 return TRUE; 121 121 } 122 else if( st == 0 || ( st < 0 && !s ockerr_again() ) )122 else if( st == 0 || ( st < 0 && !ssl_sockerr_again( jd->ssl ) ) ) 123 123 { 124 124 /* Set fd to -1 to make sure we won't write to it anymore. */ … … 231 231 } 232 232 } 233 else if( st == 0 || ( st < 0 && !s ockerr_again() ) )233 else if( st == 0 || ( st < 0 && !ssl_sockerr_again( jd->ssl ) ) ) 234 234 { 235 235 closesocket( jd->fd ); -
protocols/jabber/iq.c
rdc0ba9c reded1f7 50 50 else if( strcmp( type, "get" ) == 0 ) 51 51 { 52 if( !( c = xt_find_node( node->children, "query" ) ) || 52 if( !( ( c = xt_find_node( node->children, "query" ) ) || 53 ( c = xt_find_node( node->children, "ping" ) ) ) || /* O_o WHAT is wrong with just <query/> ????? */ 53 54 !( s = xt_find_attr( c, "xmlns" ) ) ) 54 55 { … … 81 82 xt_add_child( reply, xt_new_node( "tz", buf, NULL ) ); 82 83 } 84 else if( strcmp( s, XMLNS_PING ) == 0 ) 85 { 86 xt_free_node( reply ); 87 reply = jabber_make_packet( "iq", "result", xt_find_attr( node, "from" ), NULL ); 88 if( ( s = xt_find_attr( node, "id" ) ) ) 89 xt_add_attr( reply, "id", s ); 90 pack = 0; 91 } 83 92 else if( strcmp( s, XMLNS_DISCO_INFO ) == 0 ) 84 93 { … … 87 96 XMLNS_CHATSTATES, 88 97 XMLNS_MUC, 98 XMLNS_PING, 89 99 XMLNS_SI, 90 100 XMLNS_BYTESTREAMS, -
protocols/jabber/jabber.c
rdc0ba9c reded1f7 423 423 } 424 424 425 static void jabber_chat_invite_( struct groupchat *c, char *who, char *msg ) 426 { 427 struct jabber_chat *jc = c->data; 428 gchar *msg_alt = NULL; 429 430 if( msg == NULL ) 431 msg_alt = g_strdup_printf( "%s invited you to %s", c->ic->acc->user, jc->name ); 432 433 if( c && who ) 434 jabber_chat_invite( c, who, msg ? msg : msg_alt ); 435 436 g_free( msg_alt ); 437 } 438 425 439 static void jabber_keepalive( struct im_connection *ic ) 426 440 { … … 494 508 ret->chat_msg = jabber_chat_msg_; 495 509 ret->chat_topic = jabber_chat_topic_; 496 // ret->chat_invite = jabber_chat_invite;510 ret->chat_invite = jabber_chat_invite_; 497 511 ret->chat_leave = jabber_chat_leave_; 498 512 ret->chat_join = jabber_chat_join_; -
protocols/jabber/jabber.h
rdc0ba9c reded1f7 189 189 #define XMLNS_VERSION "jabber:iq:version" /* XEP-0092 */ 190 190 #define XMLNS_TIME "jabber:iq:time" /* XEP-0090 */ 191 #define XMLNS_PING "urn:xmpp:ping" /* XEP-0199 */ 191 192 #define XMLNS_VCARD "vcard-temp" /* XEP-0054 */ 192 193 #define XMLNS_DELAY "jabber:x:delay" /* XEP-0091 */ … … 293 294 void jabber_chat_pkt_presence( struct im_connection *ic, struct jabber_buddy *bud, struct xt_node *node ); 294 295 void jabber_chat_pkt_message( struct im_connection *ic, struct jabber_buddy *bud, struct xt_node *node ); 296 void jabber_chat_invite( struct groupchat *c, char *who, char *message ); 295 297 296 298 #endif -
protocols/msn/msn.c
rdc0ba9c reded1f7 241 241 } 242 242 243 static void msn_chat_invite( struct groupchat *c, char * msg, char *who)243 static void msn_chat_invite( struct groupchat *c, char *who, char *message ) 244 244 { 245 245 struct msn_switchboard *sb = msn_sb_by_chat( c ); -
protocols/oscar/aim.h
rdc0ba9c reded1f7 94 94 * 95 95 */ 96 #define AIM_DEFAULT_LOGIN_SERVER "login. oscar.aol.com"96 #define AIM_DEFAULT_LOGIN_SERVER "login.messaging.aol.com" 97 97 #define AIM_LOGIN_PORT 5190 98 98 -
protocols/oscar/oscar.c
rdc0ba9c reded1f7 341 341 set_t *s; 342 342 343 s = set_add( &acc->set, "server", NULL, set_eval_account, acc );343 s = set_add( &acc->set, "server", AIM_DEFAULT_LOGIN_SERVER, set_eval_account, acc ); 344 344 s->flags |= ACC_SET_NOSAVE | ACC_SET_OFFLINE_ONLY; 345 345 … … 356 356 struct oscar_data *odata = ic->proto_data = g_new0(struct oscar_data, 1); 357 357 358 if (isdigit(acc->user[0])) { 359 odata->icq = TRUE; 360 /* This is odd but it's necessary for a proper do_import and do_export. 361 We don't do those anymore, but let's stick with it, just in case 362 it accidentally fixes something else too... </bitlbee> */ 363 /* ic->acc->pass[8] = 0; 364 Not touching this anymore now that it belongs to account_t! 365 Let's hope nothing will break. ;-) */ 366 } else { 358 if (!isdigit(acc->user[0])) { 367 359 ic->flags |= OPT_DOES_HTML; 368 360 } … … 385 377 } 386 378 387 if (acc->server == NULL) {388 imcb_error(ic, "No servername specified");389 imc_logout(ic, FALSE);390 return;391 }392 393 if (g_strcasecmp(acc->server, "login.icq.com") != 0 &&394 g_strcasecmp(acc->server, "login.oscar.aol.com") != 0) {395 imcb_log(ic, "Warning: Unknown OSCAR server: `%s'. Please review your configuration if the connection fails.",acc->server);396 }397 398 379 imcb_log(ic, _("Signon: %s"), ic->acc->user); 399 380 … … 402 383 403 384 conn->status |= AIM_CONN_STATUS_INPROGRESS; 404 conn->fd = proxy_connect(acc->server, AIM_LOGIN_PORT, oscar_login_connect, ic); 385 conn->fd = proxy_connect(set_getstr(&acc->set, "server"), 386 AIM_LOGIN_PORT, oscar_login_connect, ic); 405 387 if (conn->fd < 0) { 406 388 imcb_error(ic, _("Couldn't connect to host")); … … 2509 2491 } 2510 2492 2511 void oscar_chat_invite(struct groupchat *c, char * message, char *who)2493 void oscar_chat_invite(struct groupchat *c, char *who, char *message) 2512 2494 { 2513 2495 struct im_connection *ic = c->ic; -
protocols/yahoo/yahoo.c
rdc0ba9c reded1f7 306 306 } 307 307 308 static void byahoo_chat_invite( struct groupchat *c, char * msg, char *who)308 static void byahoo_chat_invite( struct groupchat *c, char *who, char *msg ) 309 309 { 310 310 struct byahoo_data *yd = (struct byahoo_data *) c->ic->proto_data;
Note: See TracChangeset
for help on using the changeset viewer.