diff options
Diffstat (limited to 'mkfs.c')
-rw-r--r-- | mkfs.c | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -51,6 +51,7 @@ xint(uint x) return y; } +int main(int argc, char *argv[]) { int i, cc, fd; @@ -111,6 +112,13 @@ main(int argc, char *argv[]) perror(argv[i]); exit(1); } + + // Skip leading _ in name when writing to file system. + // The binaries are named _rm, _cat, etc. to keep the + // build operating system from trying to execute them + // in place of system binaries like rm and cat. + if(argv[i][0] == '_') + ++argv[i]; inum = ialloc(T_FILE); |