Actually wait on the provided fd in __read Change-Id: Iad7f6e8529741c4ff8851c4db44e8141403d3810
diff --git a/linenoise.c b/linenoise.c index 503355b..6d37b72 100644 --- a/linenoise.c +++ b/linenoise.c
@@ -145,8 +145,8 @@ if (len == 0) return 0; for (;;) { - mxio_wait_fd(0, MXIO_EVT_READABLE, NULL, MX_TIME_INFINITE); - if ((nread = read(0, buf, len))) + mxio_wait_fd(fd, MXIO_EVT_READABLE, NULL, MX_TIME_INFINITE); + if ((nread = read(fd, buf, len))) return nread; }