changeset 24662:5d61c3793c06

(cp-coding-system-for-codepage-1): Make the magnification parameter for the -dos encoder be 2.
author Andrew Innes <andrewi@gnu.org>
date Sun, 02 May 1999 09:48:22 +0000
parents a969304198eb
children 39edc9c7b235
files lisp/international/codepage.el
diffstat 1 files changed, 5 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/international/codepage.el	Sun May 02 09:45:17 1999 +0000
+++ b/lisp/international/codepage.el	Sun May 02 09:48:22 1999 +0000
@@ -88,7 +88,11 @@
 		       (repeat)))))
 	   (ccl-encoder-dos
 	    (ccl-compile
-	     `(1 (loop (read-multibyte-character r0 r1)
+	     ;; The 2 here supplies the buf_magnification parameter for
+	     ;; the CCL program.  Since the -dos coding system generates
+	     ;; \r\n for each \n, a factor of 2 covers even the worst case
+	     ;; of empty lines with a single \n.
+	     `(2 (loop (read-multibyte-character r0 r1)
 		       (if (r1 == ?\n)
 			   (write ?\r)
 			 (if (r0 != ,(charset-id 'ascii))