chiark / gitweb /
[PATCH] more Libsysfs updates
[elogind.git] / libsysfs / sysfs_device.c
index e3a89770160f90f4c264da4e27af3112d0647e14..290fd9723e2094ea07439901d9d2e7a7b7acd128 100644 (file)
@@ -53,7 +53,7 @@ static int get_dev_driver(struct sysfs_device *dev)
        if (c == NULL)
                return 1;
        *c = '\0';
-       safestrncat(c, path, (sizeof(devpath) - strlen(devpath)));
+       safestrcatmax(c, path, (sizeof(devpath) - strlen(devpath)));
 
        drvlist = sysfs_open_subsystem_list(path);
        if (drvlist != NULL) {