minor fixes
This commit is contained in:
parent
4ea67234e0
commit
a34831a2e9
@ -248,7 +248,7 @@ static int sck_on_read (hio_dev_sck_t* sck, const void* data, hio_iolen_t dlen,
|
||||
|
||||
if (!sess || !sess->active)
|
||||
{
|
||||
/* discard the record. no associated sessoin or inactive session */
|
||||
/* discard the record. no associated session or inactive session */
|
||||
goto back_to_header;
|
||||
}
|
||||
|
||||
|
@ -773,6 +773,14 @@ struct hio_cmgr_t
|
||||
# define HIO_UNUSED
|
||||
#endif
|
||||
|
||||
#if defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 202311L)
|
||||
# define HIO_NORETURN noreturn
|
||||
#elif defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 201112L)
|
||||
# define HIO_NORETURN _Noreturn
|
||||
#else
|
||||
# define HIO_NORETURN
|
||||
#endif
|
||||
|
||||
/**
|
||||
* The HIO_TYPE_IS_SIGNED() macro determines if a type is signed.
|
||||
* \code
|
||||
@ -1004,7 +1012,9 @@ struct hio_cmgr_t
|
||||
#define HIO_STATIC_JOIN_INNER(x, y) x ## y
|
||||
#define HIO_STATIC_JOIN(x, y) HIO_STATIC_JOIN_INNER(x, y)
|
||||
|
||||
#if defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 201112L)
|
||||
#if defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 202311L)
|
||||
# define HIO_STATIC_ASSERT(expr) static_assert (expr, "invalid assertion")
|
||||
#elif defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 201112L)
|
||||
# define HIO_STATIC_ASSERT(expr) _Static_assert (expr, "invalid assertion")
|
||||
#elif defined(__cplusplus) && (__cplusplus >= 201103L)
|
||||
# define HIO_STATIC_ASSERT(expr) static_assert (expr, "invalid assertion")
|
||||
|
@ -1031,7 +1031,7 @@ int hio_svc_htts_docgi (hio_svc_htts_t* htts, hio_dev_sck_t* csck, hio_htre_t* r
|
||||
|
||||
if ((n = bind_task_to_peer(cgi, csck, req, docroot, script)) <= -1)
|
||||
{
|
||||
if (n == -2) status_code == HIO_HTTP_STATUS_FORBIDDEN;
|
||||
if (n == -2) status_code = HIO_HTTP_STATUS_FORBIDDEN;
|
||||
goto oops;
|
||||
}
|
||||
bound_to_peer = 1;
|
||||
|
@ -388,7 +388,7 @@ static void fcgi_client_on_disconnect (hio_dev_sck_t* sck)
|
||||
|
||||
static int fcgi_client_on_read (hio_dev_sck_t* sck, const void* buf, hio_iolen_t len, const hio_skad_t* srcaddr)
|
||||
{
|
||||
hio_t* hio = sck->hio;
|
||||
hio_t* hio HIO_UNUSED = sck->hio;
|
||||
hio_svc_htts_cli_t* cli = hio_dev_sck_getxtn(sck);
|
||||
fcgi_t* fcgi = (fcgi_t*)cli->task;
|
||||
int n;
|
||||
@ -429,7 +429,7 @@ oops:
|
||||
|
||||
static int fcgi_client_on_write (hio_dev_sck_t* sck, hio_iolen_t wrlen, void* wrctx, const hio_skad_t* dstaddr)
|
||||
{
|
||||
hio_t* hio = sck->hio;
|
||||
hio_t* hio HIO_UNUSED = sck->hio;
|
||||
hio_svc_htts_cli_t* cli = hio_dev_sck_getxtn(sck);
|
||||
fcgi_t* fcgi = (fcgi_t*)cli->task;
|
||||
int n;
|
||||
@ -464,7 +464,7 @@ static int peer_capture_request_header (hio_htre_t* req, const hio_bch_t* key, c
|
||||
{
|
||||
fcgi_t* fcgi = (fcgi_t*)ctx;
|
||||
hio_svc_htts_t* htts = fcgi->htts;
|
||||
hio_t* hio = htts->hio;
|
||||
hio_t* hio HIO_UNUSED = htts->hio;
|
||||
|
||||
if (hio_comp_bcstr(key, "Connection", 1) != 0 &&
|
||||
hio_comp_bcstr(key, "Transfer-Encoding", 1) != 0 &&
|
||||
|
Loading…
Reference in New Issue
Block a user