[vinagre] Get the right port from command line
- From: Jonh Wendell <jwendell src gnome org>
- To: svn-commits-list gnome org
- Subject: [vinagre] Get the right port from command line
- Date: Wed, 27 May 2009 21:56:45 -0400 (EDT)
commit 358b78f4cddda372aec3a7b207913318c04bd352
Author: Jonh Wendell <jwendell gnome org>
Date: Wed May 27 21:22:24 2009 -0300
Get the right port from command line
---
src/vinagre-connection.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/vinagre-connection.c b/src/vinagre-connection.c
index 595b236..52b5daf 100644
--- a/src/vinagre-connection.c
+++ b/src/vinagre-connection.c
@@ -581,12 +581,12 @@ vinagre_connection_split_string (const gchar *uri,
if (g_strrstr (lhost, "::") != NULL)
{
server = g_strsplit (lhost, "::", 2);
- lport = server[1] ? atoi (server[1]) : vinagre_connection_default_port [*protocol];
+ lport = server[1] ? atoi (server[1]) : vinagre_connection_default_port [*protocol-1];
}
else
{
server = g_strsplit (lhost, ":", 2);
- lport = server[1] ? atoi (server[1]) : vinagre_connection_default_port [*protocol];
+ lport = server[1] ? atoi (server[1]) : vinagre_connection_default_port [*protocol-1];
if ((*protocol == VINAGRE_CONNECTION_PROTOCOL_VNC) && (lport < 1024))
lport += 5900;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]