From ca5140c7141b2d651a0e47770439be14341ad48b Mon Sep 17 00:00:00 2001 From: Jan Nieuwenhuizen Date: Thu, 24 Oct 2019 21:44:40 +0200 Subject: [PATCH] core: read_string: Prepare for M2-Planet. * src/string.c (read_string): Prepare for M2-Planet. --- src/string.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/string.c b/src/string.c index a8e26de9..639c3c4c 100644 --- a/src/string.c +++ b/src/string.c @@ -169,8 +169,9 @@ SCM read_string (SCM port) /*:((arity . n)) */ { int fd = __stdin; - if (TYPE (port) == TPAIR && TYPE (car (port)) == TNUMBER) - __stdin = VALUE (CAR (port)); + if (TYPE (port) == TPAIR) + if (TYPE (car (port)) == TNUMBER) + __stdin = VALUE (CAR (port)); int c = readchar (); size_t i = 0; while (c != -1)