summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--pith/mailindx.c14
-rw-r--r--pith/pine.hlp5
2 files changed, 14 insertions, 5 deletions
diff --git a/pith/mailindx.c b/pith/mailindx.c
index f6a2ba5b..efa6854d 100644
--- a/pith/mailindx.c
+++ b/pith/mailindx.c
@@ -655,17 +655,20 @@ parse_index_format(char *format_str, INDEX_COL_S **answer)
/* ignore unrecognized word */
if(!pt){
+ char c;
for(q = p; *p && !isspace((unsigned char)*p); p++)
;
- if(*p)
- *p++ = '\0';
+ if((c = *p) != '\0')
+ *p++ = '\0';
dprint((1,
"parse_index_format: unrecognized token: %s\n",
q ? q : "?"));
q_status_message1(SM_ORDER | SM_DING, 0, 3,
_("Unrecognized word in index-format: %s"), q);
+ if(c != '\0')
+ *(p-1) = c;
continue;
}
@@ -4990,8 +4993,11 @@ date_str(char *datesrc, IndexColType type, int v, char *str, size_t str_len,
? month_abbrev_locale(d.month) : "???", sizeof(monabb));
monabb[sizeof(monabb)-1] = '\0';
- if(d.day >= 1 && d.day <= 31)
- snprintf(dayzero, sizeof(dayzero), "%02d", d.day);
+ if(d.day >= 1 && d.day <= 31){
+ snprintf(dayzero, sizeof(dayzero), "%*d", 2, d.day);
+// if(d.day < 10)
+// dayzero[0] = ' ';
+ }
else{
strncpy(dayzero, "??", sizeof(dayzero));
dayzero[sizeof(dayzero)-1] = '\0';
diff --git a/pith/pine.hlp b/pith/pine.hlp
index 22269013..e6b66081 100644
--- a/pith/pine.hlp
+++ b/pith/pine.hlp
@@ -140,7 +140,7 @@ with help text for the config screen and the composer that didn't have any
reasonable place to be called from.
Dummy change to get revision in pine.hlp
============= h_revision =================
-Alpine Commit 196 2016-12-18 22:45:44
+Alpine Commit 197 2016-12-20 21:55:31
============= h_news =================
<HTML>
<HEAD>
@@ -441,6 +441,9 @@ Bugs that have been addressed include:
messages other than top of threads could appear in the index, making
Alpine display messages &quot;out of the screen.&quot;
+ <LI> The index format would be chopped at the position of an unrecognized
+ token, instead of skipping the token as intended.
+
<LI> Work in progress: Avoid calling non-safe functions when Alpine
receives a signal. See bug report
<A HREF="https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=825772">here.</A>