X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=blobdiff_plain;f=cproxy.c;h=4f9a3ffa591c8b00833d0f6b24c69f83ca64ec06;hb=808aa643e67986c22c17d5f2ef8cae52e64a31ee;hp=934ce3dc228d6f26f5f66d9074e6b11327afd6ca;hpb=a1f3b7a358adaa7c2a98359cd0373aa823eeb14b;p=PuTTY.git diff --git a/cproxy.c b/cproxy.c index 934ce3dc..4f9a3ffa 100644 --- a/cproxy.c +++ b/cproxy.c @@ -21,7 +21,7 @@ static void hmacmd5_chap(const unsigned char *challenge, int challen, void *hmacmd5_ctx; int pwlen; - hmacmd5_ctx = hmacmd5_make_context(); + hmacmd5_ctx = hmacmd5_make_context(NULL); pwlen = strlen(passwd); if (pwlen>64) { @@ -173,7 +173,8 @@ int proxy_socks5_selectchap(Proxy_Socket p) chapbuf[5] = '\x02'; /* Second attribute - username */ ulen = strlen(username); - if (ulen > 255) ulen = 255; if (ulen < 1) ulen = 1; + if (ulen > 255) ulen = 255; + if (ulen < 1) ulen = 1; chapbuf[6] = ulen; memcpy(chapbuf+7, username, ulen);