emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] emacs/lib-src ChangeLog b2m.c [EMACS_23_1_RC]


From: Chong Yidong
Subject: [Emacs-diffs] emacs/lib-src ChangeLog b2m.c [EMACS_23_1_RC]
Date: Wed, 08 Jul 2009 03:17:48 +0000

CVSROOT:        /sources/emacs
Module name:    emacs
Branch:         EMACS_23_1_RC
Changes by:     Chong Yidong <cyd>      09/07/08 03:17:48

Modified files:
        lib-src        : ChangeLog b2m.c 

Log message:
        * b2m.c (main): Ensure that each message ends in two newlines.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/emacs/lib-src/ChangeLog?cvsroot=emacs&only_with_tag=EMACS_23_1_RC&r1=2.530.2.1&r2=2.530.2.2
http://cvs.savannah.gnu.org/viewcvs/emacs/lib-src/b2m.c?cvsroot=emacs&only_with_tag=EMACS_23_1_RC&r1=1.32&r2=1.32.8.1

Patches:
Index: ChangeLog
===================================================================
RCS file: /sources/emacs/emacs/lib-src/ChangeLog,v
retrieving revision 2.530.2.1
retrieving revision 2.530.2.2
diff -u -b -r2.530.2.1 -r2.530.2.2
--- ChangeLog   3 Jul 2009 13:59:19 -0000       2.530.2.1
+++ ChangeLog   8 Jul 2009 03:17:48 -0000       2.530.2.2
@@ -1,3 +1,7 @@
+2009-07-08  E. Jay Berkenbilt  <address@hidden>  (tiny change)
+
+       * b2m.c (main): Ensure that each message ends in two newlines.
+
 2009-07-03  Eli Zaretskii  <address@hidden>
 
        * makefile.w32-in (WINNT_SUPPORT): Add term/common-win.elc, like

Index: b2m.c
===================================================================
RCS file: /sources/emacs/emacs/lib-src/b2m.c,v
retrieving revision 1.32
retrieving revision 1.32.8.1
diff -u -b -r1.32 -r1.32.8.1
--- b2m.c       4 Apr 2006 04:13:01 -0000       1.32
+++ b2m.c       8 Jul 2009 03:17:48 -0000       1.32.8.1
@@ -94,7 +94,7 @@
      int argc;
      char **argv;
 {
-  logical labels_saved, printing, header;
+  logical labels_saved, printing, header, first, last_was_blank_line;
   time_t ltoday;
   struct tm *tm;
   char *labels, *p, *today;
@@ -139,7 +139,8 @@
       exit (EXIT_SUCCESS);
     }
 
-  labels_saved = printing = header = FALSE;
+  labels_saved = printing = header = last_was_blank_line = FALSE;
+  first = TRUE;
   ltoday = time (0);
   /* Convert to a string, checking for out-of-range time stamps.
      Don't use 'ctime', as that might dump core if the hardware clock
@@ -170,6 +171,10 @@
            continue;
          else if (data.buffer[1] == '\f')
            {
+             if (first)
+               first = FALSE;
+             else if (! last_was_blank_line)
+               puts("");
              /* Save labels. */
              readline (&data, stdin);
              p = strtok (data.buffer, " ,\r\n\t");
@@ -195,7 +200,13 @@
        }
 
       if (printing)
+       {
        puts (data.buffer);
+         if (data.buffer[0] == '\0')
+           last_was_blank_line = TRUE;
+         else
+           last_was_blank_line = FALSE;
+       }
     }
 
   return EXIT_SUCCESS;




reply via email to

[Prev in Thread] Current Thread [Next in Thread]