X11 Forwarding and Red Hat

Michael H. Warfield mhw at wittsend.com
Fri May 19 04:52:01 EST 2000


On Thu, May 18, 2000 at 09:28:05PM +0200, Markus Friedl wrote:
> does this help?

	Yes...  That appears to fix my problem.

> Index: session.c
> ===================================================================
> RCS file: /home/markus/cvs/ssh/session.c,v
> retrieving revision 1.12
> diff -u -r1.12 session.c
> --- session.c	2000/05/03 18:03:07	1.12
> +++ session.c	2000/05/18 19:18:53
> @@ -949,13 +953,20 @@
>  		else {
>  			/* Add authority data to .Xauthority if appropriate. */
>  			if (auth_proto != NULL && auth_data != NULL) {
> -				if (debug_flag)
> +				char *screen = strchr(display, ':');
> +				if (debug_flag) {
>  					fprintf(stderr, "Running %.100s add %.100s %.100s %.100s\n",
> -						XAUTH_PATH, display, auth_proto, auth_data);
> -
> +					    XAUTH_PATH, display, auth_proto, auth_data);
> +					if (screen != NULL)
> +						fprintf(stderr, "Adding %.*s/unix%s %s %s\n",
> +						    screen-display, display, screen, auth_proto, auth_data);
> +				}
>  				f = popen(XAUTH_PATH " -q -", "w");
>  				if (f) {
>  					fprintf(f, "add %s %s %s\n", display, auth_proto, auth_data);
> +					if (screen != NULL) 
> +						fprintf(f, "add %.*s/unix%s %s %s\n",
> +						     screen-display, display, screen, auth_proto, auth_data);
>  					pclose(f);
>  				} else
>  					fprintf(stderr, "Could not run %s -q -\n", XAUTH_PATH);

-- 
 Michael H. Warfield    |  (770) 985-6132   |  mhw at WittsEnd.com
  (The Mad Wizard)      |  (770) 331-2437   |  http://www.wittsend.com/mhw/
  NIC whois:  MHW9      |  An optimist believes we live in the best of all
 PGP Key: 0xDF1DD471    |  possible worlds.  A pessimist is sure of it!






More information about the openssh-unix-dev mailing list