From d4ba1e134fcce95f8b7983fa9fba6d9d18f8f68b Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Mon, 27 Aug 2012 15:07:36 -0500 Subject: If we've got a colon for a port number split that out --- src/freerdp-auth-check.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src') diff --git a/src/freerdp-auth-check.c b/src/freerdp-auth-check.c index 83bab2f..d50833b 100644 --- a/src/freerdp-auth-check.c +++ b/src/freerdp-auth-check.c @@ -79,6 +79,15 @@ main (int argc, char * argv[]) instance->settings->password = password; instance->settings->ignore_certificate = true; + char * colonloc = strstr(argv[1], ":"); + if (colonloc != NULL) { + /* We've got a port to deal with */ + colonloc[0] = '\0'; + colonloc++; + + instance->settings->port = strtoul(colonloc, NULL, 10); + } + if (freerdp_connect(instance)) { freerdp_disconnect(instance); return 0; -- cgit v1.2.3