]> granicus.if.org Git - mutt/commitdiff
Decrement the mtime of the tempfile during edit-message to make mutt
authorGary Johnson <Gary Johnson>
Fri, 31 Aug 2007 17:12:18 +0000 (10:12 -0700)
committerGary Johnson <Gary Johnson>
Fri, 31 Aug 2007 17:12:18 +0000 (10:12 -0700)
notice changes taking less than one second.

ChangeLog
editmsg.c

index 98218d4c028391830cb60aac3cf7519856b8097b..fa17e5947cf6bbd0dcaf98f081b23f9149da4080 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,4 +1,10 @@
-2007-08-28 10:43 -0700  Brendan Cully  <brendan@kublai.com>  (3cc89213ebb7)
+2007-08-28 11:33 -0700  Brendan Cully  <brendan@kublai.com>  (3f8829e739e9)
+
+       * init.h: Insert .pp after .de to fix man page generation (closes
+       #2940)
+
+       * imap/imap.c: Check subscriptions after any authentication,
+       rather than after fist connection (closes #2908)
 
        * dotlock.c, lib.h, mutt.h: Use limits.h for PATH_MAX instead of
        posix1_lim.h (closes #2525)
index 6729973971ddf8ccbe997b47b2d7b537b0279de4..e6c603f52fe844c9e43779ac83a3b86058395bcf 100644 (file)
--- a/editmsg.c
+++ b/editmsg.c
@@ -91,8 +91,11 @@ static int edit_one_message (CONTEXT *ctx, HEADER *cur)
     goto bail;
   }
 
-  if (stat (tmp, &sb) == 0)
-    mtime = sb.st_mtime;
+  if ((rc = stat (tmp, &sb)) == -1)
+  {
+    mutt_error (_("Can't stat %s: %s"), tmp, strerror (errno));
+    goto bail;
+  }
 
   /*
    * 2002-09-05 me@sigpipe.org
@@ -109,6 +112,8 @@ static int edit_one_message (CONTEXT *ctx, HEADER *cur)
     goto bail;
   }
 
+  mtime = mutt_decrease_mtime (tmp, &sb);
+
   mutt_edit_file (NONULL(Editor), tmp);
 
   if ((rc = stat (tmp, &sb)) == -1)