Changeset b46769d
- Timestamp:
- 2010-08-12T22:44:56Z (14 years ago)
- Branches:
- master
- Children:
- 91d6e91
- Parents:
- be7a180
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
lib/xmltree.c
rbe7a180 rb46769d 550 550 } 551 551 552 /* Same, but at the beginning. */ 553 void xt_insert_child( struct xt_node *parent, struct xt_node *child ) 554 { 555 struct xt_node *node, *last; 556 557 for( node = child; node; node = node->next ) 558 { 559 if( node->parent != NULL ) 560 { 561 /* ERROR CONDITION: They seem to have a parent already??? */ 562 } 563 564 node->parent = parent; 565 last = node; 566 } 567 568 last->next = parent->children; 569 parent->children = child; 570 } 571 552 572 void xt_add_attr( struct xt_node *node, const char *key, const char *value ) 553 573 { -
lib/xmltree.h
rbe7a180 rb46769d 92 92 struct xt_node *xt_new_node( char *name, const char *text, struct xt_node *children ); 93 93 void xt_add_child( struct xt_node *parent, struct xt_node *child ); 94 void xt_insert_child( struct xt_node *parent, struct xt_node *child ); 94 95 void xt_add_attr( struct xt_node *node, const char *key, const char *value ); 95 96 int xt_remove_attr( struct xt_node *node, const char *key ); -
protocols/msn/ns.c
rbe7a180 rb46769d 228 228 else if( strcmp( cmd[2], "OK" ) == 0 ) 229 229 { 230 if( num_parts == 7 )231 msn_ns_got_display_name( ic, cmd[4] );232 else233 imcb_log( ic, "Warning: Friendly name in server response was corrupted" );234 235 230 imcb_log( ic, "Authenticated, getting buddy list" ); 236 237 231 msn_soap_memlist_request( ic ); 238 232 } … … 246 240 else if( strcmp( cmd[0], "MSG" ) == 0 ) 247 241 { 248 if( num_parts !=4 )242 if( num_parts < 4 ) 249 243 { 250 244 imcb_error( ic, "Syntax error" ); … … 348 342 const struct msn_away_state *st; 349 343 350 if( num_parts !=5 )344 if( num_parts < 5 ) 351 345 { 352 346 imcb_error( ic, "Syntax error" ); … … 377 371 int session, port; 378 372 379 if( num_parts !=7 )373 if( num_parts < 7 ) 380 374 { 381 375 imcb_error( ic, "Syntax error" ); … … 421 415 else if( strcmp( cmd[0], "ADD" ) == 0 ) 422 416 { 423 if( num_parts == 6 && strcmp( cmd[2], "RL" ) == 0 )417 if( num_parts >= 6 && strcmp( cmd[2], "RL" ) == 0 ) 424 418 { 425 419 GSList *l; … … 485 479 else if( strcmp( cmd[0], "REA" ) == 0 ) 486 480 { 487 if( num_parts !=5 )481 if( num_parts < 5 ) 488 482 { 489 483 imcb_error( ic, "Syntax error" ); -
protocols/msn/sb.c
rbe7a180 rb46769d 414 414 else if( strcmp( cmd[0], "USR" ) == 0 ) 415 415 { 416 if( num_parts !=5 )416 if( num_parts < 5 ) 417 417 { 418 418 msn_sb_destroy( sb ); … … 440 440 int num, tot; 441 441 442 if( num_parts !=6 )442 if( num_parts < 6 ) 443 443 { 444 444 msn_sb_destroy( sb ); … … 477 477 else if( strcmp( cmd[0], "ANS" ) == 0 ) 478 478 { 479 if( num_parts !=3 )479 if( num_parts < 3 ) 480 480 { 481 481 msn_sb_destroy( sb ); … … 496 496 else if( strcmp( cmd[0], "CAL" ) == 0 ) 497 497 { 498 if( num_parts !=4 || !isdigit( cmd[3][0] ) )498 if( num_parts < 4 || !isdigit( cmd[3][0] ) ) 499 499 { 500 500 msn_sb_destroy( sb ); … … 506 506 else if( strcmp( cmd[0], "JOI" ) == 0 ) 507 507 { 508 if( num_parts !=3 )508 if( num_parts < 3 ) 509 509 { 510 510 msn_sb_destroy( sb ); … … 567 567 else if( strcmp( cmd[0], "MSG" ) == 0 ) 568 568 { 569 if( num_parts !=4 )569 if( num_parts < 4 ) 570 570 { 571 571 msn_sb_destroy( sb );
Note: See TracChangeset
for help on using the changeset viewer.