aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2012-08-27 15:02:23 -0500
committerTed Gould <ted@gould.cx>2012-08-27 15:02:23 -0500
commit027417a45b1b5a991d9ac06a01d96a86c80832bc (patch)
tree9c1e2b6836d039a537d8ab6a69bb942632df1bc9 /src
parent54985ce2584c25a6cc3886f0c4b3df593184a52a (diff)
downloadlibpam-freerdp2-027417a45b1b5a991d9ac06a01d96a86c80832bc.tar.gz
libpam-freerdp2-027417a45b1b5a991d9ac06a01d96a86c80832bc.tar.bz2
libpam-freerdp2-027417a45b1b5a991d9ac06a01d96a86c80832bc.zip
Switch to looking for '://' in the string
Diffstat (limited to 'src')
-rw-r--r--src/pam-freerdp.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/pam-freerdp.c b/src/pam-freerdp.c
index 2550767..440ee40 100644
--- a/src/pam-freerdp.c
+++ b/src/pam-freerdp.c
@@ -88,9 +88,10 @@ get_item (pam_handle_t * pamh, int type)
free(responses);
if (type == PAM_RHOST) {
- if (strncmp(retval, "http://", strlen("http://")) == 0) {
+ char * subloc = NULL;
+ if ((subloc = strstr(retval, "://")) != NULL) {
char * original = retval;
- char * newish = retval + strlen("http://");
+ char * newish = retval + strlen("://");
char * c;
for (c = newish; *c != '\0'; c++) {
if (*c == '/') {