Minor test and type fixes

This commit is contained in:
Olof Hagsand 2021-06-26 21:27:59 +00:00
parent e451b7f43e
commit b46418d774
2 changed files with 6 additions and 2 deletions

View file

@ -604,6 +604,10 @@ Note that in this case SSL_ERROR_ZERO_RETURN does not necessarily indicate that
}
SSL_free(rc->rc_ssl);
rc->rc_ssl = NULL;
#ifdef HAVE_LIBEVHTP
if (rc->rc_evconn)
rc->rc_evconn->ssl = NULL;
#endif
}
if (close(rc->rc_s) < 0){
clicon_err(OE_UNIX, errno, "close");
@ -641,7 +645,7 @@ send_badrequest(clicon_handle h,
cprintf(cb, "HTTP/1.1 400 Bad Request\r\nConnection: close\r\n");
if (body){
cprintf(cb, "Content-Type: %s\r\n", media);
cprintf(cb, "Content-Length: %u\r\n", strlen(body));
cprintf(cb, "Content-Length: %zu\r\n", strlen(body));
}
else
cprintf(cb, "Content-Length: 0\r\n");