diff options
author | Robert Morris <[email protected]> | 2019-08-27 13:13:03 -0400 |
---|---|---|
committer | Robert Morris <[email protected]> | 2019-08-27 13:13:03 -0400 |
commit | 64b93d175ac6eb739036b394fbb0766fbf06f5b7 (patch) | |
tree | 7914971346f770276a307763449700353a5003c1 /user/cat.c | |
parent | a3f6d9fd1e21a7339f2bc26f185f7d561bc370c4 (diff) | |
download | xv6-labs-64b93d175ac6eb739036b394fbb0766fbf06f5b7.tar.gz xv6-labs-64b93d175ac6eb739036b394fbb0766fbf06f5b7.tar.bz2 xv6-labs-64b93d175ac6eb739036b394fbb0766fbf06f5b7.zip |
user printf(1 -> printf(
Diffstat (limited to 'user/cat.c')
-rw-r--r-- | user/cat.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -11,12 +11,12 @@ cat(int fd) while((n = read(fd, buf, sizeof(buf))) > 0) { if (write(1, buf, n) != n) { - printf(1, "cat: write error\n"); + printf("cat: write error\n"); exit(); } } if(n < 0){ - printf(1, "cat: read error\n"); + printf("cat: read error\n"); exit(); } } @@ -33,7 +33,7 @@ main(int argc, char *argv[]) for(i = 1; i < argc; i++){ if((fd = open(argv[i], 0)) < 0){ - printf(1, "cat: cannot open %s\n", argv[i]); + printf("cat: cannot open %s\n", argv[i]); exit(); } cat(fd); |