diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/inputStream_http.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/inputStream_http.c b/src/inputStream_http.c index 4374d654d..fc274800b 100644 --- a/src/inputStream_http.c +++ b/src/inputStream_http.c @@ -165,9 +165,10 @@ static char * proxyAuthString(char * user, char * password) { if(!user || !password) return NULL; templen = strlen(user) + strlen(password) + 2; - temp = calloc(templen, 1); - snprintf(temp, templen, "%s:%s", user, password); - temp[templen-1] = '\0'; + temp = malloc(templen); + strcpy(temp, user); + strcat(temp, ":"); + strcat(temp, password); temp64 = base64Dup(temp); free(temp); |