Merge remote-tracking branch 'origin/master' into riscv
This commit is contained in:
commit
e10f797762
|
@ -241,7 +241,6 @@ bad:
|
||||||
static struct inode*
|
static struct inode*
|
||||||
create(char *path, short type, short major, short minor)
|
create(char *path, short type, short major, short minor)
|
||||||
{
|
{
|
||||||
uint off;
|
|
||||||
struct inode *ip, *dp;
|
struct inode *ip, *dp;
|
||||||
char name[DIRSIZ];
|
char name[DIRSIZ];
|
||||||
|
|
||||||
|
@ -249,7 +248,7 @@ create(char *path, short type, short major, short minor)
|
||||||
return 0;
|
return 0;
|
||||||
ilock(dp);
|
ilock(dp);
|
||||||
|
|
||||||
if((ip = dirlookup(dp, name, &off)) != 0){
|
if((ip = dirlookup(dp, name, 0)) != 0){
|
||||||
iunlockput(dp);
|
iunlockput(dp);
|
||||||
ilock(ip);
|
ilock(ip);
|
||||||
if(type == T_FILE && (ip->type == T_FILE || ip->type == T_DEVICE))
|
if(type == T_FILE && (ip->type == T_FILE || ip->type == T_DEVICE))
|
||||||
|
|
Loading…
Reference in a new issue