unix: Routines related to terminal reading should use system malloc.

Otherwise we have mixup between system and GC alloc.