X-Git-Url: https://diplodocus.org/git/nmh/blobdiff_plain/93a18dd7a6b92922361383a4e6152380da5f3583..92c3b05ef3e582d64b3cecfc261fdd66ef13a4ef:/uip/mhical.c diff --git a/uip/mhical.c b/uip/mhical.c index 3249d085..d62fce95 100644 --- a/uip/mhical.c +++ b/uip/mhical.c @@ -535,11 +535,10 @@ output (FILE *file, contentline *clines, int contenttype) { line = fold (add (node->value, line), clines->cr_before_lf == CR_BEFORE_LF); - if (clines->cr_before_lf == LF_ONLY) { - fprintf (file, "%s\n", line); - } else { - fprintf (file, "%s\r\n", line); - } + fputs(line, file); + if (clines->cr_before_lf != LF_ONLY) + putc('\r', file); + putc('\n', file); free (line); } }