From 41bcad9c194d92ba90f6f42f680087efa4f0e998 Mon Sep 17 00:00:00 2001 From: Ayke van Laethem Date: Fri, 5 Nov 2021 19:05:22 +0100 Subject: [PATCH] runtime: only use CRLF on baremetal systems We should only do this on baremetal systems, not on Linux, macOS, and Windows. In fact, Windows will convert LF into CRLF in its putchar function. --- src/runtime/print.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/runtime/print.go b/src/runtime/print.go index 04336cce..2c78c822 100644 --- a/src/runtime/print.go +++ b/src/runtime/print.go @@ -273,7 +273,9 @@ func printspace() { } func printnl() { - putchar('\r') + if baremetal { + putchar('\r') + } putchar('\n') }