aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/inputStream_http.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/inputStream_http.c b/src/inputStream_http.c
index 5330dfe62..e12866ef6 100644
--- a/src/inputStream_http.c
+++ b/src/inputStream_http.c
@@ -259,8 +259,8 @@ static int parseUrl(InputStreamHTTPData * data, char * url) {
}
else {
user = malloc(at-temp+1);
- strncpy(user, temp, colon-temp);
- user[colon-temp] = '\0';
+ strncpy(user, temp, at-temp);
+ user[at-temp] = '\0';
passwd = strdup("");
}