summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephen Hemminger <stephen.hemminger@vyatta.com>2010-07-16 15:12:24 -0700
committerStephen Hemminger <stephen.hemminger@vyatta.com>2010-07-16 15:12:24 -0700
commit97d8757a2fe575b2aba258859c8df37ca9ed7cf6 (patch)
tree8ca6895e022a4fcdeedbd9b531264c25a27af94f
parentf27cda6960d996564470be15a6cebc796949514f (diff)
parente3439e45dcd2cea98e6f99f0bc316931ca402822 (diff)
downloadvyatta-cfg-97d8757a2fe575b2aba258859c8df37ca9ed7cf6.tar.gz
vyatta-cfg-97d8757a2fe575b2aba258859c8df37ca9ed7cf6.zip
Merge branch 'larkspur' of suva.vyatta.com:/git/vyatta-cfg into larkspur
-rw-r--r--debian/changelog6
-rwxr-xr-xscripts/vyatta-comment-config.pl12
2 files changed, 16 insertions, 2 deletions
diff --git a/debian/changelog b/debian/changelog
index 1daa29e..d4fb331 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+vyatta-cfg (0.16.96) unstable; urgency=low
+
+ * fix for bug 5794. Comments are not allowed on multinode parent.
+
+ -- Michael Larson <slioch@slioch.vyatta.com> Fri, 16 Jul 2010 13:49:35 -0700
+
vyatta-cfg (0.16.95) unstable; urgency=low
* fix for bug 5789 and bug 5860
diff --git a/scripts/vyatta-comment-config.pl b/scripts/vyatta-comment-config.pl
index 2cbd81d..5e3a315 100755
--- a/scripts/vyatta-comment-config.pl
+++ b/scripts/vyatta-comment-config.pl
@@ -23,6 +23,7 @@ use strict;
use warnings;
use File::Find;
use lib "/opt/vyatta/share/perl5";
+use Vyatta::Config;
sub usage() {
@@ -55,11 +56,17 @@ if (! -e $full_path) {
$full_path = "$ENV{VYATTA_TEMP_CONFIG_DIR}/$path";
}
else {
- `echo \"Path is not valid\n\"`;
+ print "Configuation path is not valid\n";
exit 0;
}
}
+my $config = new Vyatta::Config;
+my @el = split('/',$edit_level);
+if ($config->isTagNode([ @el, @path ])) {
+ print "Cannot set comment without value for this path\n";
+ exit 0;
+}
#scan for illegal characters here: '/*', '*/'
if ($ARGV[$#ARGV] =~ /\/\*|\*\//) {
print "illegal characters found in comment\n";
@@ -80,5 +87,6 @@ else {
close($cfile);
}
-print "Done\n";
+`touch $ENV{VYATTA_TEMP_CONFIG_DIR}/.modified`;
+
exit 0;