From 282b51807dd0268adb4d7cf849b8f6e125309bad Mon Sep 17 00:00:00 2001 From: Tejun Heo Date: Thu, 14 Jun 2007 03:45:13 +0900 Subject: [PATCH] --- yaml --- r: 59113 b: refs/heads/master c: 7a23ad44047b1084a032bc0d127fe08af024593a h: refs/heads/master i: 59111: c8b2acc740c66f601d300eec8a112c4c5a2d516f v: v3 --- [refs] | 2 +- trunk/fs/sysfs/sysfs.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/[refs] b/[refs] index 89489c274413..124d5f16a2e4 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 2b611bb7abdcc08278453fc9f6517401fd69ef95 +refs/heads/master: 7a23ad44047b1084a032bc0d127fe08af024593a diff --git a/trunk/fs/sysfs/sysfs.h b/trunk/fs/sysfs/sysfs.h index 687d959f606d..f4fdbbffd571 100644 --- a/trunk/fs/sysfs/sysfs.h +++ b/trunk/fs/sysfs/sysfs.h @@ -111,7 +111,7 @@ static inline struct sysfs_dirent * sysfs_get(struct sysfs_dirent * sd) static inline void sysfs_put(struct sysfs_dirent * sd) { - if (atomic_dec_and_test(&sd->s_count)) + if (sd && atomic_dec_and_test(&sd->s_count)) release_sysfs_dirent(sd); }