diff options
| author | Dan Cross <cross@gajendra.net> | 2019-03-21 01:15:38 +0000 | 
|---|---|---|
| committer | Frans Kaashoek <kaashoek@mit.edu> | 2019-08-19 13:22:35 -0400 | 
| commit | 0581c37baf8950ae9602a1419498a800f9fade4f (patch) | |
| tree | 6e57d803cd6240d4ef25efd11450cadc2f5c90e5 | |
| parent | b818915f793cd20c5d1e24f668534a9d690f3cc8 (diff) | |
| download | xv6-labs-0581c37baf8950ae9602a1419498a800f9fade4f.tar.gz xv6-labs-0581c37baf8950ae9602a1419498a800f9fade4f.tar.bz2 xv6-labs-0581c37baf8950ae9602a1419498a800f9fade4f.zip | |
Removed unused `dirlookup` argument in `create`
The `off` argument to `dirlookup` is optional.  It
was not being used in the `dirlookup` call in `create`,
so pass NULL instead and delete the unused local.
Signed-off-by: Dan Cross <cross@gajendra.net>
| -rw-r--r-- | sysfile.c | 3 | 
1 files changed, 1 insertions, 2 deletions
| @@ -241,7 +241,6 @@ bad:  static struct inode*  create(char *path, short type, short major, short minor)  { -  uint off;    struct inode *ip, *dp;    char name[DIRSIZ]; @@ -249,7 +248,7 @@ create(char *path, short type, short major, short minor)      return 0;    ilock(dp); -  if((ip = dirlookup(dp, name, &off)) != 0){ +  if((ip = dirlookup(dp, name, 0)) != 0){      iunlockput(dp);      ilock(ip);      if(type == T_FILE && ip->type == T_FILE) | 
