mdadm/mdadm-3.0.3-auto.patch

26 lines
583 B
Diff

--- mdadm-3.0.3/config.c 2009-10-01 02:57:03.000000000 -0400
+++ mdadm-3.0.3/config.c 2010-01-04 11:24:58.700853405 -0500
@@ -677,12 +677,21 @@
static char *auto_options = NULL;
void autoline(char *line)
{
+ char *w;
+
if (auto_options) {
fprintf(stderr, Name ": AUTO line may only be give once."
" Subsequent lines ignored\n");
return;
}
- auto_options = line;
+
+ auto_options = dl_strdup(line);
+ dl_init(auto_options);
+
+ for (w=dl_next(line); w != line ; w=dl_next(w)) {
+ char *w2 = dl_strdup(w);
+ dl_add(auto_options, w2);
+ }
}
int loaded = 0;