comparison src/oscar.c @ 392:df5127560034

[gaim-migrate @ 402] More updates to plugins committer: Tailor Script <tailor@pidgin.im>
author Eric Warmenhoven <eric@warmenhoven.org>
date Mon, 12 Jun 2000 13:07:53 +0000
parents 7fb34b73946a
children 7c74e2f579b5
comparison
equal deleted inserted replaced
391:be408b41c172 392:df5127560034
209 debug_print(debug_buff); 209 debug_print(debug_buff);
210 210
211 if (sess->logininfo.errorcode) { 211 if (sess->logininfo.errorcode) {
212 switch (sess->logininfo.errorcode) { 212 switch (sess->logininfo.errorcode) {
213 case 0x18: 213 case 0x18:
214 do_error_dialog(_("You have been connecting and disconnecting too frequently. Wait ten minutes and try again. If you continue to try, you will need to wait even longer."), _("Gaim - Error")); 214 /* connecting too frequently */
215 strtok("983:", ":");
216 show_error_dialog("983");
215 break; 217 break;
216 case 0x05: 218 case 0x05:
217 do_error_dialog(_("Incorrect nickname or password."), _("Gaim - Error")); 219 /* Incorrect nick/password */
220 strtok("980:", ":");
221 show_error_dialog("980");
218 break; 222 break;
219 case 0x1c: 223 case 0x1c:
220 do_error_dialog(_("AOL has decided your client is too old. Please download a newer version from http://www.marko.net/gaim/"), _("Gaim - Error")); 224 /* client too old */
225 strtok("981:", ":");
226 show_error_dialog("981");
221 break; 227 break;
222 } 228 }
223 sprintf(debug_buff, "Login Error Code 0x%04x\n", 229 sprintf(debug_buff, "Login Error Code 0x%04x\n",
224 sess->logininfo.errorcode); 230 sess->logininfo.errorcode);
225 debug_print(debug_buff); 231 debug_print(debug_buff);
580 int gaim_parse_misses(struct aim_session_t *sess, 586 int gaim_parse_misses(struct aim_session_t *sess,
581 struct command_rx_struct *command, ...) { 587 struct command_rx_struct *command, ...) {
582 u_short family; 588 u_short family;
583 u_short subtype; 589 u_short subtype;
584 590
585 char buf[2048], buf2[256];
586 sprintf(buf2, _("Gaim - Error"));
587 buf[0] = 0;
588
589 family = aimutil_get16(command->data+0); 591 family = aimutil_get16(command->data+0);
590 subtype = aimutil_get16(command->data+2); 592 subtype = aimutil_get16(command->data+2);
591 593
592 switch (family) { 594 switch (family) {
593 case 0x0001: 595 case 0x0001:
594 if (subtype == 0x000a) 596 if (subtype == 0x000a) {
595 sprintf(buf, _("You are sending messages too fast.")); 597 /* sending messages too fast */
598 /* this also gets sent to us when our warning level
599 * changes, don't ask me why or how to interpret it */
600 strtok("960:someone", ":");
601 show_error_dialog("960");
602 }
596 break; 603 break;
597 case 0x0002: 604 case 0x0002:
598 if (subtype == 0x0001) 605 if (subtype == 0x0001) {
599 sprintf(buf, _("Unknown SNAC error (I'm hungry)")); 606 /* unknown SNAC error */
607 strtok("970:", ":");
608 show_error_dialog("970");
609 }
600 break; 610 break;
601 case 0x0004: 611 case 0x0004:
602 if (subtype == 0x0001) 612 if (subtype == 0x0001) {
603 sprintf(buf, _("User is not online.")); 613 /* user is not logged in */
604 else if (subtype == 0x000a) 614 strtok("901:User", ":");
605 sprintf(buf, _("A message has been dropped.")); 615 show_error_dialog("901");
606 break; 616 } else if (subtype == 0x000a) {
607 } 617 /* message has been dropped */
608 618 strtok("903:", ":");
609 if (buf[0] != 0) 619 show_error_dialog("903");
610 do_error_dialog(buf, buf2); 620 }
621 break;
622 }
611 623
612 return 1; 624 return 1;
613 } 625 }
614 626
615 int gaim_parse_user_info(struct aim_session_t *sess, 627 int gaim_parse_user_info(struct aim_session_t *sess,
626 prof = va_arg(ap, char *); 638 prof = va_arg(ap, char *);
627 infotype = va_arg(ap, u_short); 639 infotype = va_arg(ap, u_short);
628 va_end(ap); 640 va_end(ap);
629 641
630 if (prof == NULL || !strlen(prof)) { 642 if (prof == NULL || !strlen(prof)) {
631 do_error_dialog(_("User has no info/away message."), 643 /* no info/away message */
632 _("Gaim - User Info")); 644 strtok("977:", ":");
645 show_error_dialog("977");
633 return 1; 646 return 1;
634 } 647 }
635 648
636 snprintf(buf, sizeof buf, _("Username : <B>%s</B>\n<BR>" 649 snprintf(buf, sizeof buf, _("Username : <B>%s</B>\n<BR>"
637 "Warning Level : <B>%d %%</B>\n<BR>" 650 "Warning Level : <B>%d %%</B>\n<BR>"