diff options
-rw-r--r-- | utility.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -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; |