aboutsummaryrefslogtreecommitdiff
path: root/lib/http.c
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2004-02-23 08:22:43 +0000
committerDaniel Stenberg <daniel@haxx.se>2004-02-23 08:22:43 +0000
commite1b5e15431c95cc24665753ed31543c2ce6a55ab (patch)
tree7ab27a66c4bca3e07e0bb48595dea53375af063d /lib/http.c
parent1aba4c519b5389c2930075d4f555a003904a0431 (diff)
More size_t cleanups in the base64 functions.
Diffstat (limited to 'lib/http.c')
-rw-r--r--lib/http.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/http.c b/lib/http.c
index 09e1fc4c2..dade9601f 100644
--- a/lib/http.c
+++ b/lib/http.c
@@ -127,7 +127,7 @@ static CURLcode Curl_output_basic(struct connectdata *conn)
sprintf(data->state.buffer, "%s:%s", conn->user, conn->passwd);
if(Curl_base64_encode(data->state.buffer, strlen(data->state.buffer),
- &authorization) >= 0) {
+ &authorization) > 0) {
if(conn->allocptr.userpwd)
free(conn->allocptr.userpwd);
conn->allocptr.userpwd = aprintf( "Authorization: Basic %s\015\012",
@@ -147,7 +147,7 @@ static CURLcode Curl_output_basic_proxy(struct connectdata *conn)
sprintf(data->state.buffer, "%s:%s",
conn->proxyuser, conn->proxypasswd);
if(Curl_base64_encode(data->state.buffer, strlen(data->state.buffer),
- &authorization) >= 0) {
+ &authorization) > 0) {
Curl_safefree(conn->allocptr.proxyuserpwd);
conn->allocptr.proxyuserpwd =
aprintf("Proxy-authorization: Basic %s\015\012", authorization);