summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lib/device/device.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/device/device.c b/lib/device/device.c
index 3e5e2a41..a87ae7ff 100644
--- a/lib/device/device.c
+++ b/lib/device/device.c
@@ -361,7 +361,7 @@ static unsigned long _dev_topology_attribute(const char *attribute,
const char *sysfs_dir,
struct device *dev)
{
- const char *sysfs_fmt_str = "%s/dev/block/%d:%d/%s";
+ static const char sysfs_fmt_str[] = "%s/dev/block/%d:%d/%s";
char path[PATH_MAX+1], buffer[64];
FILE *fp;
struct stat info;