]> git.proxmox.com Git - pve-common.git/blobdiff - src/PVE/SectionConfig.pm
improve asciidoc markup
[pve-common.git] / src / PVE / SectionConfig.pm
index be13056eb1106468256fb05179f03b8b630d02b0..95e166abce88d8101368ee93213b7dda33532525 100644 (file)
@@ -68,7 +68,6 @@ sub createSchema {
     };
 
     foreach my $p (keys %$propertyList) {
-       next if $p eq 'type';
        if (!$propertyList->{$p}->{optional}) {
            $props->{$p} = $propertyList->{$p};
            next;
@@ -394,6 +393,9 @@ my $format_config_line = sub {
 
     my $ct = $schema->{type};
 
+    die "property '$key' contains a line feed\n"
+       if ($key =~ m/[\n\r]/) || ($value =~ m/[\n\r]/);
+
     if ($ct eq 'boolean') {
        return $value ? "\t$key\n" : '';
     } else {