From 729ddadd9af045dda9b0180ce0de705eb3837082 Mon Sep 17 00:00:00 2001 From: Julian Blake Kongslie Date: Wed, 13 Oct 2010 10:33:41 -0700 Subject: Correct error handling somewhat. --- usr/src/pinyadmin/bin/pinyconfig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'usr') diff --git a/usr/src/pinyadmin/bin/pinyconfig b/usr/src/pinyadmin/bin/pinyconfig index e18ac30..ac91c09 100755 --- a/usr/src/pinyadmin/bin/pinyconfig +++ b/usr/src/pinyadmin/bin/pinyconfig @@ -20,7 +20,7 @@ if ( defined $value ) { eval { $repo->config->$attr( $value ); }; - if ( defined $@ ) { + if ( $@ ) { print STDERR "$attr is not a legal tweakable, or $value is not a legal value for that tweakable.\n$@\n"; }; }; @@ -29,6 +29,6 @@ undef $@; eval { print "$attr = " . $repo->config->$attr . "\n"; }; -if ( defined $@ ) { +if ( $@ ) { print STDERR "$attr is not a legal tweakable, or its current value is illegal.\n$@\n"; }; -- cgit v1.2.3