diff src/fileio.c @ 13451:3a69848f7892

(Fwrite_region): Move the code that writes annotations for empty files.
author Richard M. Stallman <rms@gnu.org>
date Fri, 10 Nov 1995 06:44:54 +0000
parents 994440ef957f
children 2178c4d6a427
line wrap: on
line diff
--- a/src/fileio.c	Fri Nov 10 06:41:14 1995 +0000
+++ b/src/fileio.c	Fri Nov 10 06:44:54 1995 +0000
@@ -3427,13 +3427,12 @@
 	  nwritten += XINT (end) - tem;
 	  save_errno = errno;
 	}
-
-      if (nwritten == 0)
-	{
-	  /* If file was empty, still need to write the annotations */
-	  failure = 0 > a_write (desc, "", 0, XINT (start), &annotations);
-	  save_errno = errno;
-	}
+    }
+  else
+    {
+      /* If file was empty, still need to write the annotations */
+      failure = 0 > a_write (desc, "", 0, XINT (start), &annotations);
+      save_errno = errno;
     }
 
   immediate_quit = 0;