Added flag so .bash_logout won't try to unregister a socket that didn't register.
This commit is contained in:
parent
8bce5d846c
commit
dae5b0fdaa
3 changed files with 7 additions and 5 deletions
|
|
@ -18,7 +18,7 @@ hash ssh-add ssh-agent >/dev/null 2>&1 && {
|
|||
_PLATFORM="$(uname -s)"
|
||||
|
||||
# Remove the SSH_AUTH_SOCK from the agents file.
|
||||
[[ ! -z "$SSH_AUTH_SOCK" ]] && {
|
||||
[[ ! -z "$SSH_AUTH_SOCK" ]] && (( ${_SSH_AGENT_REG_FAILED:-0} == 0 )) && {
|
||||
_lock_agents_file && {
|
||||
_pop_agent_sock || {
|
||||
echo -e "$(tput setaf 1 || tput AF 1)Failed to clean up agents file!$(tput op)"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue