summaryrefslogtreecommitdiffstats
path: root/super0.c
diff options
context:
space:
mode:
Diffstat (limited to 'super0.c')
-rw-r--r--super0.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/super0.c b/super0.c
index 0364da4..303ed88 100644
--- a/super0.c
+++ b/super0.c
@@ -117,7 +117,7 @@ static void examine_super0(void *sbv)
char nb[5];
if (d>=0) dp = &sb->disks[d];
else dp = &sb->this_disk;
- sprintf(nb, "%4d", d);
+ snprintf(nb, sizeof(nb), "%4d", d);
printf("%4s %5d %5d %5d %5d ", d < 0 ? "this" : nb,
dp->number, dp->major, dp->minor, dp->raid_disk);
if (dp->state & (1<<MD_DISK_FAULTY)) printf(" faulty");