mirror of
git://sourceware.org/git/lvm2.git
synced 2025-01-18 10:04:20 +03:00
Make it possible to represent type-correct single-item arrays in config trees.
This commit is contained in:
parent
cc6032956f
commit
0a305e9666
@ -486,11 +486,11 @@ static int _write_config(const struct config_node *n, int only_one,
|
|||||||
line_append("=");
|
line_append("=");
|
||||||
if (v->next) {
|
if (v->next) {
|
||||||
line_append("[");
|
line_append("[");
|
||||||
while (v) {
|
while (v && v->type != CFG_EMPTY_ARRAY) {
|
||||||
if (!_write_value(outline, v))
|
if (!_write_value(outline, v))
|
||||||
return_0;
|
return_0;
|
||||||
v = v->next;
|
v = v->next;
|
||||||
if (v)
|
if (v && v->type != CFG_EMPTY_ARRAY)
|
||||||
line_append(", ");
|
line_append(", ");
|
||||||
}
|
}
|
||||||
line_append("]");
|
line_append("]");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user