From f22f019aeba00ccb3cc35fe763c3e87bf5690040 Mon Sep 17 00:00:00 2001 From: dzwdz Date: Sat, 20 Aug 2022 11:11:57 +0200 Subject: user/ethdump: turn into a file server --- src/user/app/shell/builtins.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/user/app/shell') diff --git a/src/user/app/shell/builtins.c b/src/user/app/shell/builtins.c index 23a8221..1be9b5b 100644 --- a/src/user/app/shell/builtins.c +++ b/src/user/app/shell/builtins.c @@ -28,7 +28,7 @@ static void cmd_cat(int argc, char **argv) { } if (!strcmp(argv[i], "!stdin")) fextflags(file, FEXT_NOFILL); for (;;) { - int len = fread(buf, 1, sizeof buf, file); + int len = fread(buf, 1, buflen, file); if (len <= 0) break; fwrite(buf, 1, len, stdout); } -- cgit v1.2.3