summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--alpine/mailcmd.c3
-rw-r--r--alpine/titlebar.c19
-rw-r--r--pith/conf.c2
-rw-r--r--pith/conftype.h1
-rw-r--r--pith/pine.hlp48
-rw-r--r--pith/save.c1
6 files changed, 71 insertions, 3 deletions
diff --git a/alpine/mailcmd.c b/alpine/mailcmd.c
index a4fa5247..e4208d21 100644
--- a/alpine/mailcmd.c
+++ b/alpine/mailcmd.c
@@ -3494,6 +3494,9 @@ save_size_changed_prompt(long msgno, int flags)
{-1, 0, NULL, NULL}
};
+ if(F_ON(F_IGNORE_SIZE, ps_global))
+ return 'y';
+
if(flags & SSCP_INIT || flags & SSCP_END){
if(flags & SSCP_END && possible_corruption)
q_status_message(SM_ORDER, 3, 3, "There is possible data corruption, check the results");
diff --git a/alpine/titlebar.c b/alpine/titlebar.c
index 2fc35d8d..fa825be9 100644
--- a/alpine/titlebar.c
+++ b/alpine/titlebar.c
@@ -83,7 +83,8 @@ static struct titlebar_state {
del_column,
percent_column,
page_column,
- screen_cols;
+ screen_cols,
+ pushed;
enum {Normal, OnlyRead, Closed} stream_status;
TitleBarType style;
TITLE_S titlecontainer;
@@ -92,13 +93,20 @@ static struct titlebar_state {
static int titlebar_is_dirty = 1;
+char *as_fname; /* folder name */
+char *as_cname; /* context name */
void
push_titlebar_state(void)
{
+ as.pushed = 1;
titlebar_stack = as;
- as.folder_name = NULL; /* erase knowledge of malloc'd data */
- as.context_name = NULL;
+ if(as_fname) fs_give((void **)&as_fname);
+ as_fname = cpystr(as.folder_name);
+ if(as_cname) fs_give((void **)&as_cname);
+ as_cname = cpystr(as.context_name);
+ if(as.folder_name) fs_give((void **)&as.folder_name);
+ if(as.context_name) fs_give((void **)&as.context_name);
}
@@ -110,6 +118,11 @@ pop_titlebar_state(void)
fs_give((void **)&(as.folder_name)); /* free malloc'd values */
fs_give((void **)&(as.context_name));
as = titlebar_stack;
+ if(as.pushed){
+ as.folder_name = as_fname ? cpystr(as_fname) : NULL;
+ as.context_name = as_cname ? cpystr(as_cname): NULL;
+ }
+ as.pushed = 0;
}
}
diff --git a/pith/conf.c b/pith/conf.c
index 6a803932..6e320527 100644
--- a/pith/conf.c
+++ b/pith/conf.c
@@ -3140,6 +3140,8 @@ feature_list(int index)
F_FULL_AUTO_EXPUNGE, h_config_full_auto_expunge, PREF_MISC, 0},
{"force-arrow-cursor", NULL,
F_FORCE_ARROW, h_config_force_arrow, PREF_MISC, 0},
+ {"ignore-size-changes", NULL,
+ F_IGNORE_SIZE, h_config_ignore_size, PREF_MISC, 0},
{"maildrops-preserve-state", NULL,
F_MAILDROPS_PRESERVE_STATE, h_config_maildrops_preserve_state,
PREF_MISC, 0},
diff --git a/pith/conftype.h b/pith/conftype.h
index 3c9316fa..afae74ec 100644
--- a/pith/conftype.h
+++ b/pith/conftype.h
@@ -346,6 +346,7 @@ typedef enum {
F_FORCE_ARROW,
F_PRUNE_USES_ISO,
F_ALT_ED_NOW,
+ F_IGNORE_SIZE,
F_SHOW_DELAY_CUE,
F_CANCEL_CONFIRM,
F_AUTO_OPEN_NEXT_UNREAD,
diff --git a/pith/pine.hlp b/pith/pine.hlp
index 2e0fd0c4..6b3ec1ba 100644
--- a/pith/pine.hlp
+++ b/pith/pine.hlp
@@ -335,6 +335,12 @@ Bugs that have been addressed include:
of the certificate to lowercase, which may make Alpine not be able
to read such certificate. Reported by Dennis Davis.
+ <LI> Bug: Crash when attempting to read a message after a bounce
+ command. In order to produce a crash one needed to use the ^T
+ subcommand and do a search in a LDAP directory. The crash is
+ produced by changes to the text in the title bar. Reported by
+ Heinrich Mislik in the Alpine-info list.
+
<LI> Pico: Searching for a string that is too long causes Pico to crash
in the next search.
@@ -3771,6 +3777,7 @@ There are also additional details on
<li><a href="h_config_full_auto_expunge">FEATURE: <!--#echo var="FEAT_expunge-without-confirm-everywhere"--></a>
<li><a href="h_config_no_fcc_attach">FEATURE: <!--#echo var="FEAT_fcc-without-attachments"--></a>
<li><a href="h_config_force_arrow">FEATURE: <!--#echo var="FEAT_force-arrow-cursor"--></a>
+<li><a href="h_config_ignore_size">FEATURE: <!--#echo var="FEAT_ignore-size-changes"--></a>
<li><a href="h_config_forward_as_attachment">FEATURE: <!--#echo var="FEAT_forward-as-attachment"--></a>
<li><a href="h_config_preserve_field">FEATURE: <!--#echo var="FEAT_preserve-original-fields"--></a>
<li><a href="h_config_quell_empty_dirs">FEATURE: <!--#echo var="FEAT_quell-empty-directories"--></a>
@@ -31167,6 +31174,47 @@ but that is not implemented.
&lt;End of help on this topic&gt;
</BODY>
</HTML>
+====== h_config_ignore_size =====
+<HTML>
+<HEAD>
+<TITLE>FEATURE: <!--#echo var="FEAT_ignore-size-changes"--></TITLE>
+</HEAD>
+<BODY>
+<H1>FEATURE: <!--#echo var="FEAT_ignore-size-changes"--></H1>
+
+When you have an account residing in an IMAP server, Alpine records the
+size of each message as reported by the server. However, when Alpine saves
+a message in such IMAP server, Alpine will compute the size of the message
+independently, from the data it received. If these two numbers do not
+match for a message, Alpine asks you if you still want to take the risk of
+saving such message, since data corruption or loss of data could result
+from this save.
+
+<P>
+Sometimes the root of this problem is that the IMAP server does not
+compute sizes correctly, and there will not be loss of information when
+saving such message. Enabling this feature will make Alpine ignore such
+error and continue saving the message without producing any warnings or
+ever stopping the process, as if there had not been any error. This option
+applies to all IMAP servers that you use, so if you enable this feature,
+size discrepancy warnings will not be given for any IMAP server you
+connect to.
+
+<P>
+Example of a server where you could reproduce this problem is the Gmail
+IMAP server. Another example can be found in some versions of the Exchange
+server.
+
+<P>
+It is recommended that this feature be disabled most of the time and only
+enabled when you find a server which you can determine that has the above
+mentioned defect, but be disabled again after making the save operation
+succeed.
+
+<P>
+&lt;End of help on this topic&gt;
+</BODY>
+</HTML>
====== h_config_force_low_speed =====
<HTML>
<HEAD>
diff --git a/pith/save.c b/pith/save.c
index e2e68651..f6f45b0a 100644
--- a/pith/save.c
+++ b/pith/save.c
@@ -1157,6 +1157,7 @@ long save_fetch_append_cb(MAILSTREAM *stream, void *data, char **flags,
snprintf(buf, sizeof(buf),
"Message to save shrank: source msg # %ld may be saved incorrectly",
mn_raw2m(pkg->msgmap, raw));
+ if(F_OFF(F_IGNORE_SIZE, ps_global))
q_status_message(SM_ORDER, 0, 3, buf);
}
else{