summaryrefslogtreecommitdiff
path: root/fs
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2010-09-08 01:04:59 +0400
committerLinus Torvalds <torvalds@linux-foundation.org>2010-09-08 01:04:59 +0400
commitd3de0eb1642feda3c53fb455e7cf07b222deafb5 (patch)
treeee010c5fcbed7c42710e25ba1b7950b4c118f20a /fs
parentb06ac5a3606d365a63e671273a441158ce3019bb (diff)
parent57f9bdac2510cd7fda58e4a111d250861eb1ebeb (diff)
downloadlinux-d3de0eb1642feda3c53fb455e7cf07b222deafb5.tar.xz
Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core-2.6: sysfs: checking for NULL instead of ERR_PTR
Diffstat (limited to 'fs')
-rw-r--r--fs/sysfs/file.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/sysfs/file.c b/fs/sysfs/file.c
index 1b27b5688f62..da3fefe91a8f 100644
--- a/fs/sysfs/file.c
+++ b/fs/sysfs/file.c
@@ -340,7 +340,7 @@ static int sysfs_open_file(struct inode *inode, struct file *file)
char *p;
p = d_path(&file->f_path, last_sysfs_file, sizeof(last_sysfs_file));
- if (p)
+ if (!IS_ERR(p))
memmove(last_sysfs_file, p, strlen(p) + 1);
/* need attr_sd for attr and ops, its parent for kobj */