aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--utility.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/utility.c b/utility.c
index 3422d997a..28e333e6f 100644
--- a/utility.c
+++ b/utility.c
@@ -1636,7 +1636,7 @@ extern int find_real_root_device_name(char* name)
1636 if (strcmp(entry->d_name, "..") == 0) 1636 if (strcmp(entry->d_name, "..") == 0)
1637 continue; 1637 continue;
1638 1638
1639 sprintf( fileName, "/dev/%s", entry->d_name); 1639 snprintf( fileName, strlen(name)+1, "/dev/%s", entry->d_name);
1640 1640
1641 if (stat(fileName, &statBuf) != 0) 1641 if (stat(fileName, &statBuf) != 0)
1642 continue; 1642 continue;