From 34554ff77baca463a83b5d90ddebfcd352a9da59 Mon Sep 17 00:00:00 2001 From: Jakob Dietrich Date: Wed, 29 Aug 2018 00:39:32 +0200 Subject: [PATCH] Add newline in vmir_puts --- src/vmir_libc.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/vmir_libc.c b/src/vmir_libc.c index dd42f66..30d4094 100644 --- a/src/vmir_libc.c +++ b/src/vmir_libc.c @@ -928,8 +928,10 @@ static int vmir_puts(void *ret, const void *rf, ir_unit_t *iu) { const char *str = vmir_vm_ptr(&rf, iu); - if(iu->iu_stdout != NULL) + if(iu->iu_stdout != NULL) { fwrite(str, strlen(str), 1, iu->iu_stdout->fp); + fwrite("\n", 1, 1, iu->iu_stdout->fp); + } vmir_vm_ret32(ret, 0); return 0; }