diff options
Diffstat (limited to 'contrib/ashctl.c')
-rw-r--r-- | contrib/ashctl.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/contrib/ashctl.c b/contrib/ashctl.c index 10975899..39a45dbb 100644 --- a/contrib/ashctl.c +++ b/contrib/ashctl.c @@ -68,8 +68,8 @@ u: fprintf(stderr, "usage: ashctl <port> [raw|normal]\n" } sleep(1); - read(fd, buf, BUFSIZ-1); - buf[BUFSIZ-1] = '\0'; + i = read(fd, buf, BUFSIZ-1); + buf[i] = '\0'; if (strstr(buf, "$PASH") || strstr(buf, "$GP")) goto done; } |