Patch: Elm ME+ 2.5 PLalpha49 -> Elm ME+ 2.5 PLalpha50 [1/7] (4/4)
From
Kari Hurtta@21:1/5 to
All on Mon Jun 10 20:44:54 2019
[continued from previous message]
char *code; /* Do not free() this -- this is just pointer
to read_tokens area
*/
+ int code_pos;
+
case imap_status_keyword:
Text = NULL;
code = NULL;
! code_pos = pick_text(M_a,&Text,&code);
if (0 == istrcmp(M_a->read_tokens.tokens[1].str,"BYE")) {
M_a->imap_state = IMAP_closing;
if (Text)
***************
*** 1352,1358 ****
if (IMAP_show_greeting && !code)
lib_error(CATGETS(elm_msg_cat, MeSet,MeImapServer,
"IMAP server: %S"),
! Text);
} else if (0 == istrcmp(M_a->read_tokens.tokens[1].str,"NO")) {
if (IMAP_show_greeting)
lib_error(CATGETS(elm_msg_cat, MeSet,MeImapWarning,
--- 1508,1534 ----
if (IMAP_show_greeting && !code)
lib_error(CATGETS(elm_msg_cat, MeSet,MeImapServer,
"IMAP server: %S"),
! Text);
!
! if (code && 0 == istrcmp(code,"UIDVALIDITY")) {
! if (code_pos < 0 || code_pos >= M_a->read_tokens.token_count ||
! 0 != istrcmp(M_a->read_tokens.tokens[code_pos].str,
! "UIDVALIDITY"))
! panic("MBX PANIC",__FILE__,__LINE__,"parse_response",
! "Bad code_pos",0);
!
! if (code_pos+1 < M_a->read_tokens.token_count &&
! imap_number == M_a->read_tokens.tokens[code_pos+1].imap_token) {
! if (M_b) {
! M_b->uidvalidity =
! M_a->read_tokens.tokens[code_pos+1].len_or_value;
! DPRINT(Debug,12,(&Debug,
! "parse_response: UIDVALIDITY %d\n",
! M_b->uidvalidity));
! }
! }
! }
!
} else if (0 == istrcmp(M_a->read_tokens.tokens[1].str,"NO")) {
if (IMAP_show_greeting)
lib_error(CATGETS(elm_msg_cat, MeSet,MeImapWarn
From
Kari Hurtta@21:1/5 to
All on Mon Jun 10 20:51:29 2019
[continued from previous message]
char *code; /* Do not free() this -- this is just pointer
to read_tokens area
*/
+ int code_pos;
+
case imap_status_keyword:
Text = NULL;
code = NULL;
! code_pos = pick_text(M_a,&Text,&code);
if (0 == istrcmp(M_a->read_tokens.tokens[1].str,"BYE")) {
M_a->imap_state = IMAP_closing;
if (Text)
***************
*** 1352,1358 ****
if (IMAP_show_greeting && !code)
lib_error(CATGETS(elm_msg_cat, MeSet,MeImapServer,
"IMAP server: %S"),
! Text);
} else if (0 == istrcmp(M_a->read_tokens.tokens[1].str,"NO")) {
if (IMAP_show_greeting)
lib_error(CATGETS(elm_msg_cat, MeSet,MeImapWarning,
--- 1508,1534 ----
if (IMAP_show_greeting && !code)
lib_error(CATGETS(elm_msg_cat, MeSet,MeImapServer,
"IMAP server: %S"),
! Text);
!
! if (code && 0 == istrcmp(code,"UIDVALIDITY")) {
! if (code_pos < 0 || code_pos >= M_a->read_tokens.token_count ||
! 0 != istrcmp(M_a->read_tokens.tokens[code_pos].str,
! "UIDVALIDITY"))
! panic("MBX PANIC",__FILE__,__LINE__,"parse_response",
! "Bad code_pos",0);
!
! if (code_pos+1 < M_a->read_tokens.token_count &&
! imap_number == M_a->read_tokens.tokens[code_pos+1].imap_token) {
! if (M_b) {
! M_b->uidvalidity =
! M_a->read_tokens.tokens[code_pos+1].len_or_value;
! DPRINT(Debug,12,(&Debug,
! "parse_response: UIDVALIDITY %d\n",
! M_b->uidvalidity));
! }
! }
! }
!
} else if (0 == istrcmp(M_a->read_tokens.tokens[1].str,"NO")) {
if (IMAP_show_greeting)
lib_error(CATGETS(elm_msg_cat, MeSet,MeImapWarn