aboutsummaryrefslogtreecommitdiffstats
path: root/apps.c
diff options
context:
space:
mode:
authorkraxel <kraxel>2006-11-07 14:32:36 +0000
committerkraxel <kraxel>2006-11-07 14:32:36 +0000
commit701c9668cabe7a3c2bf0151a4474b981ec010c66 (patch)
tree996b3a57028b1d707ffb61895388cacadd9509fa /apps.c
parente16c481d49db8954e9f90941265b1a75d4ada29e (diff)
downloadxenwatch-701c9668cabe7a3c2bf0151a4474b981ec010c66.tar.gz
s/displayno/tcpport/
Diffstat (limited to 'apps.c')
-rw-r--r--apps.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/apps.c b/apps.c
index fab3c4d..916b3c9 100644
--- a/apps.c
+++ b/apps.c
@@ -242,15 +242,15 @@ int run_cmdline_replace(int do_wait, char *str, ...)
/* ------------------------------------------------------------------ */
-int open_vnc_session(char *host, int screen)
+int open_vnc_session(char *host, int tcpport)
{
char display[64];
char javaurl[64];
char vncurl[64];
- snprintf(display, sizeof(display), "%s:%d", host, screen);
- snprintf(javaurl, sizeof(javaurl), "http://%s:%d/", host, 5800 + screen);
- snprintf(vncurl, sizeof(vncurl), "vnc://%s:%d/", host, 5900 + screen);
+ snprintf(display, sizeof(display), "%s:%d", host, tcpport - 5900);
+ snprintf(javaurl, sizeof(javaurl), "http://%s:%d/", host, tcpport - 100);
+ snprintf(vncurl, sizeof(vncurl), "vnc://%s:%d/", host, tcpport);
/* --- try client apps --- */
if (have_application("vncviewer"))