6148d71c1d
- Fix Monitor mode sometimes crashes when a resync completes - Fix missing symlink for mdadm container device when incremental creates the array - Make sure when creating a second array in a container that the second array uses all available space since leaving space for a third array is invalid - Validate the number of imsm volumes per controller - Fix issues with imsm arrays and disks larger than 2TB - Add support for expanding imsm arrays/containers - The support for expanding imsm arrays/containers was accepted upstream, update to the official patches from there - Fix for the issue of --add not being very smart - Fix an issue causing rebuilds to fail to restart on reboot (data corrupter level problem) - Reset the bad flag on map file updates - Correctly fix failure when trying to add internal bitmap to 1.0 arrays - Resolves: bz817023 (f17) bz817024 (f17) bz817026 (f17) bz817028 (f17) - Resolves: bz817029 (f17) bz817032 (f17) bz817038 (f17) bz808774 (f17) - Resolves: bz817039 (f17) bz817042 (f17) Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com>
35 lines
1.1 KiB
Diff
35 lines
1.1 KiB
Diff
From 8453f8d0df0111cfd25e984afb7a64153b04bc27 Mon Sep 17 00:00:00 2001
|
|
From: Lukasz Dorau <lukasz.dorau@intel.com>
|
|
Date: Thu, 12 Jan 2012 10:40:00 +1100
|
|
Subject: [PATCH] fix: Monitor sometimes crashes
|
|
|
|
The "char cnt [40]" buffer is sometimes too small to hold all message
|
|
- in such case monitor crashes.
|
|
The buffer must be larger to be able to hold all message.
|
|
|
|
Signed-off-by: Lukasz Dorau <lukasz.dorau@intel.com>
|
|
Signed-off-by: NeilBrown <neilb@suse.de>
|
|
---
|
|
Monitor.c | 5 +++--
|
|
1 files changed, 3 insertions(+), 2 deletions(-)
|
|
|
|
diff --git a/Monitor.c b/Monitor.c
|
|
index 8bc8824..77f22aa 100644
|
|
--- a/Monitor.c
|
|
+++ b/Monitor.c
|
|
@@ -563,8 +563,9 @@ static int check_array(struct state *st, struct mdstat_ent *mdstat,
|
|
struct mdinfo *sra =
|
|
sysfs_read(-1, st->devnum, GET_MISMATCH);
|
|
if (sra && sra->mismatch_cnt > 0) {
|
|
- char cnt[40];
|
|
- sprintf(cnt, " mismatches found: %d (on raid level %d)",
|
|
+ char cnt[80];
|
|
+ snprintf(cnt, sizeof(cnt),
|
|
+ " mismatches found: %d (on raid level %d)",
|
|
sra->mismatch_cnt, array.level);
|
|
alert("RebuildFinished", dev, cnt, ainfo);
|
|
} else
|
|
--
|
|
1.7.7.6
|
|
|