From f243bc74eb5012687f6fdf892d0063aa382497c8 Mon Sep 17 00:00:00 2001 From: Russ Allbery Date: Wed, 20 Feb 2008 23:07:45 +0000 Subject: Report the correct error message when addprinc fails while creating a keytab object. --- perl/Wallet/Object/Keytab.pm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'perl') diff --git a/perl/Wallet/Object/Keytab.pm b/perl/Wallet/Object/Keytab.pm index ecca270..8739f89 100644 --- a/perl/Wallet/Object/Keytab.pm +++ b/perl/Wallet/Object/Keytab.pm @@ -2,7 +2,7 @@ # $Id$ # # Written by Russ Allbery -# Copyright 2007 Board of Trustees, Leland Stanford Jr. University +# Copyright 2007, 2008 Board of Trustees, Leland Stanford Jr. University # # See LICENSE for licensing terms. @@ -24,7 +24,7 @@ use Wallet::Object::Base; # This version should be increased on any code change to this module. Always # use two digits for the minor version with a leading zero if necessary so # that it will sort properly. -$VERSION = '0.05'; +$VERSION = '0.06'; ############################################################################## # kadmin Interaction @@ -116,7 +116,7 @@ sub kadmin_addprinc { my $flags = $Wallet::Config::KEYTAB_FLAGS || ''; my $output = $self->kadmin ("addprinc -randkey $flags $principal"); if ($output =~ /^add_principal: (.*)/m) { - die "error adding principal $principal: $!\n"; + die "error adding principal $principal: $1\n"; } return 1; } -- cgit v1.2.3