summaryrefslogtreecommitdiff
path: root/libsysfs/sysfs_class.c
diff options
context:
space:
mode:
Diffstat (limited to 'libsysfs/sysfs_class.c')
-rw-r--r--libsysfs/sysfs_class.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libsysfs/sysfs_class.c b/libsysfs/sysfs_class.c
index a132bb64cb..4ea7f41c99 100644
--- a/libsysfs/sysfs_class.c
+++ b/libsysfs/sysfs_class.c
@@ -111,7 +111,7 @@ static void set_classdev_classname(struct sysfs_class_device *cdev)
if (c == NULL) {
c = strstr(cdev->path, SYSFS_BLOCK_NAME);
} else {
- c = strstr(c, "/");
+ c = strchr(c, '/');
}
if (c == NULL)