From a324d2bcb5a8fc1c8638aa19c60078b94b4e4ecf Mon Sep 17 00:00:00 2001 From: Iain Patterson Date: Fri, 7 Oct 2011 07:28:12 +0100 Subject: [PATCH 1/1] Fix argument handling with kinit. Use a function instead of an alias for kinit so arguments are not eaten. --- .profile.d/krb5.bashrc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.profile.d/krb5.bashrc b/.profile.d/krb5.bashrc index 9938a30..477dc3f 100644 --- a/.profile.d/krb5.bashrc +++ b/.profile.d/krb5.bashrc @@ -2,7 +2,7 @@ alias kssh='ssh -o preferredauthentications=gssapi-with-mic' alias pssh='ssh -o preferredauthentications=password,keyboard-interactive' unalias kinit 2>/dev/null -if [ -z "$OLDSOLARIS" -a -z "$OLDREDHAT" ]; then +if [ 1 = 0 -a -z "$OLDSOLARIS" -a -z "$OLDREDHAT" ]; then if tty -s; then if [ ! "$SUDO_UID" ]; then if klist -s 2>/dev/null; then @@ -86,4 +86,6 @@ if [ -z "$OLDSOLARIS" -a -z "$OLDREDHAT" ]; then fi unset cache ccname default ng -alias kinit='( builtin cd /; exec -c kinit )' +function kinit() { + ( builtin cd /; exec -c kinit ${1+"$@"} ) +} -- 2.20.1