From a12a3b4a387dd62c2648e820eb07a3510ffa0d36 Mon Sep 17 00:00:00 2001 From: Tejun Heo Date: Wed, 16 Jan 2008 12:06:14 +0900 Subject: [PATCH] --- yaml --- r: 75518 b: refs/heads/master c: e49452c67703d3647467d65275fb893589384fed h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/fs/sysfs/dir.c | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/[refs] b/[refs] index 9ba7fd20ad1f..f66e9476ac69 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: cbd9c883696da72b2b1f03f909dbacc04bbf8b58 +refs/heads/master: e49452c67703d3647467d65275fb893589384fed diff --git a/trunk/fs/sysfs/dir.c b/trunk/fs/sysfs/dir.c index 337162935d21..b197016bbfbe 100644 --- a/trunk/fs/sysfs/dir.c +++ b/trunk/fs/sysfs/dir.c @@ -678,8 +678,10 @@ static struct dentry * sysfs_lookup(struct inode *dir, struct dentry *dentry, sd = sysfs_find_dirent(parent_sd, dentry->d_name.name); /* no such entry */ - if (!sd) + if (!sd) { + ret = ERR_PTR(-ENOENT); goto out_unlock; + } /* attach dentry and inode */ inode = sysfs_get_inode(sd);