]> diplodocus.org Git - nmh/commitdiff
Changed sortm warning message from an amonish() to and advise(),
authorDavid Levine <levinedl@acm.org>
Sun, 27 Jan 2013 15:34:58 +0000 (09:34 -0600)
committerDavid Levine <levinedl@acm.org>
Sun, 27 Jan 2013 15:34:58 +0000 (09:34 -0600)
and included the remedy of using the file mtime, per suggestions
of Norm and Ralph.

test/folder/test-sortm
uip/sortm.c

index 7ef656cdd1cc64398f8cdce62c5aeee24f30aef9..930b0581b457a40efce754dc38f26ff8f18bfda2 100755 (executable)
@@ -388,7 +388,7 @@ check "$expected" "$actual"
 
 # check -check
 cat >"$expected" <<EOF
-sortm: can't parse date field in message 14, continuing...
+sortm: can't parse date field in message 14, will use file mtime
 sortm: errors found, no messages sorted
 EOF
 
@@ -437,7 +437,7 @@ EOF
 
 sed -e 's/Sep//' $MH_TEST_DIR/Mail/inbox/7 > $MH_TEST_DIR/Mail/inbox/14
 run_test 'sortm -check -nocheck' \
-         "sortm: can't parse date field in message 14, continuing..."
+         "sortm: can't parse date field in message 14, will use file mtime"
 scan >"$actual"
 check "$expected" "$actual"
 
index 429f75f9708c7884978a161500079ea920fd6b34..28e2bd64d9be0f9a9b7d3e04eca7025e0ea46b8b 100644 (file)
@@ -423,7 +423,8 @@ get_fields (char *datesw, int msg, struct smsg *smsg)
     if (!datecomp || (tw = dparsetime (datecomp)) == NULL) {
        struct stat st;
 
-       admonish (NULL, "can't parse %s field in message %d", datesw, msg);
+       advise (NULL, "can't parse %s field in message %d, will use file mtime",
+               datesw, msg);
        fstat (fileno (in), &st);
        smsg->s_clock = st.st_mtime;
        check_failed = 1;