From 4833cebef58214d015bb8bbaf56d5fc2b0d85d30 Mon Sep 17 00:00:00 2001 From: lissav Date: Mon, 8 Mar 2010 18:31:47 +0000 Subject: [PATCH] add already defined check git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@5404 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- perl-xCAT/xCAT/Client.pm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/perl-xCAT/xCAT/Client.pm b/perl-xCAT/xCAT/Client.pm index bb9b3c5aa..2d2449116 100644 --- a/perl-xCAT/xCAT/Client.pm +++ b/perl-xCAT/xCAT/Client.pm @@ -90,8 +90,9 @@ sub submit_request { unless ($cafile) { $cafile = xCAT::Utils->getHomeDir()."/.xcat/ca.pem"; } $xCAT::Client::EXITCODE = 0; # clear out exit code before invoking the plugin # add current userid to the request -$request->{username}->[0] = getpwuid($>); - +if (!(defined($request->{username}))) { + $request->{username}->[0] = getpwuid($>); +} # If XCATBYPASS is set, invoke the plugin process_request method directly # without going through the socket connection to the xcatd daemon if ($ENV{XCATBYPASS}) {