print agentfile also for no given identity
This commit is contained in:
parent
b01b6373d3
commit
5c45efd5e5
1 changed files with 4 additions and 5 deletions
|
@ -194,12 +194,10 @@ $(ssh_runinagent $agentfile ssh-add -l)"
|
|||
ret=0
|
||||
else
|
||||
logwarning "ssh-identity »$ssh_identity« is not configured. Please create $identitydir and add keys"
|
||||
echo $agentfile
|
||||
printf "%s" "$agentfile"
|
||||
ret=2
|
||||
fi
|
||||
|
||||
else
|
||||
|
||||
if which gnome-keyring-daemon >/dev/null 2>&1; then
|
||||
logdebug "no identity given -> gnome-keyrings ssh-agent"
|
||||
agentfile="${SSH_AGENTS_DIR}/agent-gnome_session-$(hostname)"
|
||||
|
@ -209,12 +207,12 @@ $(ssh_runinagent $agentfile ssh-add -l)"
|
|||
logdebug "ssh-agent for identity »$ssh_identity«: $agentfile"
|
||||
# logdebug "currently loaded keys after action:
|
||||
#$(ssh_runinagent $agentfile ssh-add -l)"
|
||||
printf "%s" "$agentfile"
|
||||
ret=0
|
||||
else
|
||||
logwarning "no identity given -> exit"
|
||||
ret=1
|
||||
fi
|
||||
|
||||
fi
|
||||
|
||||
[ $DISPLAY_ORIG ] && logtrace "reset DISPLAY=$DISPLAY_ORIG"
|
||||
|
@ -373,7 +371,8 @@ function check_pubkeysonly () {
|
|||
|
||||
ssh_runinagent () {
|
||||
|
||||
|
||||
local SSH_AUTH_SOCK
|
||||
local SSH_AGENT_PID
|
||||
local agentfile
|
||||
local command
|
||||
local agentfile=${1}
|
||||
|
|
Loading…
Reference in a new issue