diff options
author | Bernard Cafarelli <voyageur@gentoo.org> | 2008-09-15 14:58:30 +0000 |
---|---|---|
committer | Bernard Cafarelli <voyageur@gentoo.org> | 2008-09-15 14:58:30 +0000 |
commit | 8b82570677d4506f96537533161edfbff05cb000 (patch) | |
tree | eb98730c62c793c2544455d52bf0d84eea89b963 /net-misc/nx/files/nx-3.2.0-nxproxy_read_from_stdin.patch | |
parent | Version bump, bug #225527, thank cruzki for report. (diff) | |
download | historical-8b82570677d4506f96537533161edfbff05cb000.tar.gz historical-8b82570677d4506f96537533161edfbff05cb000.tar.bz2 historical-8b82570677d4506f96537533161edfbff05cb000.zip |
Add patch for nxproxy to read from stdin, allows nxcl to use standard ssh instead of nxssh
Package-Manager: portage-2.2_rc8/cvs/Linux 2.6.26-gentoo x86_64
Diffstat (limited to 'net-misc/nx/files/nx-3.2.0-nxproxy_read_from_stdin.patch')
-rw-r--r-- | net-misc/nx/files/nx-3.2.0-nxproxy_read_from_stdin.patch | 68 |
1 files changed, 68 insertions, 0 deletions
diff --git a/net-misc/nx/files/nx-3.2.0-nxproxy_read_from_stdin.patch b/net-misc/nx/files/nx-3.2.0-nxproxy_read_from_stdin.patch new file mode 100644 index 000000000000..bce692d10a7a --- /dev/null +++ b/net-misc/nx/files/nx-3.2.0-nxproxy_read_from_stdin.patch @@ -0,0 +1,68 @@ +--- Main.c.old 2007-07-18 17:39:13.000000000 +0200 ++++ Main.c 2008-03-12 04:40:30.000000000 +0100 +@@ -36,28 +36,48 @@ + int result = -1; + + char *options = NULL; +- ++ ++ char *nx_commfd_str = NULL; ++ + options = getenv("NX_DISPLAY"); +- +- if (NXTransParseCommandLine(argc, argv) < 0) ++ ++ if ((nx_commfd_str = getenv("NX_COMMFD")) != NULL) + { +- NXTransCleanup(); +- } ++ int nx_commfd = atoi(nx_commfd_str); + +- if (NXTransParseEnvironment(options, 0) < 0) +- { +- NXTransCleanup(); ++ if (result) ++ result = NXTransCreate(nx_commfd, NX_MODE_SERVER, options); ++ ++ // go into endless loop ++ ++ if (result) ++ { ++ while (NXTransRunning(NX_FD_ANY)) ++ result = NXTransContinue(NULL); ++ } + } ++ else ++ { ++ if (NXTransParseCommandLine(argc, argv) < 0) ++ { ++ NXTransCleanup(); ++ } ++ ++ if (NXTransParseEnvironment(options, 0) < 0) ++ { ++ NXTransCleanup(); ++ } ++ ++ /* ++ * This should not return... ++ */ ++ ++ #ifdef TEST ++ fprintf(stderr, "Main: Yielding control to NX entry point.\n"); ++ #endif + +- /* +- * This should not return... +- */ +- +- #ifdef TEST +- fprintf(stderr, "Main: Yielding control to NX entry point.\n"); +- #endif +- +- result = NXTransProxy(NX_FD_ANY, NX_MODE_ANY, NX_DISPLAY_ANY); ++ result = NXTransProxy(NX_FD_ANY, NX_MODE_ANY, NX_DISPLAY_ANY); ++ } + + /* + * ...So these should not be called. |