svn commit: r236383 - stable/8/share/examples/csh

Eitan Adler eadler at FreeBSD.org
Fri Jun 1 06:40:29 UTC 2012


Author: eadler
Date: Fri Jun  1 06:40:29 2012
New Revision: 236383
URL: http://svn.freebsd.org/changeset/base/236383

Log:
  MFC r235481:
  	Rework sample code which sets SSH_AUTH_SOCK to the user's ssh-agent
  	socket path if running
  
  PR:		167932
  Approved by:	cperciva (implicit)

Modified:
  stable/8/share/examples/csh/dot.cshrc
Directory Properties:
  stable/8/share/examples/csh/   (props changed)

Modified: stable/8/share/examples/csh/dot.cshrc
==============================================================================
--- stable/8/share/examples/csh/dot.cshrc	Fri Jun  1 06:39:55 2012	(r236382)
+++ stable/8/share/examples/csh/dot.cshrc	Fri Jun  1 06:40:29 2012	(r236383)
@@ -5,7 +5,7 @@
 
 # Sets SSH_AUTH_SOCK to the user's ssh-agent socket path if running
 if (${?SSH_AUTH_SOCK} != "1") then
-	setenv SSH_AUTH_SOCK `sockstat | grep "${USER}" | cut -d ' ' -f 6` 
+	setenv SSH_AUTH_SOCK `sockstat | grep "^${USER} " | awk '/ssh-agent/ { print $6 }'`
 endif
 
 # Change only root's prompt


More information about the svn-src-all mailing list