Lines Matching refs:code
182 lws_add_http_common_headers(struct lws *wsi, unsigned int code,
190 if (lws_add_http_header_status(wsi, code, p, end))
317 unsigned int code = _code & LWSAHH_CODE_MASK;
322 wsi->http.response_code = code;
324 wsi->http.access_log.response = (int)code;
329 n = lws_add_http2_header_status(wsi, code, p, end);
335 if (code >= 400 && code < (400 + LWS_ARRAY_SIZE(err400)))
336 description = err400[code - 400];
337 if (code >= 500 && code < (500 + LWS_ARRAY_SIZE(err500)))
338 description = err500[code - 500];
340 if (code == 100)
342 if (code == 200)
344 if (code == 304)
347 if (code >= 300 && code < 400)
357 p1, code, description);
415 lws_return_http_status(struct lws *wsi, unsigned int code,
435 code == HTTP_STATUS_NOT_FOUND)
450 if (lws_add_http_header_status(wsi, code, &p, end))
463 "</head><body><h1>%u</h1>%s</body></html>", code, html_body);
529 lws_http_redirect(struct lws *wsi, int code, const unsigned char *loc, int len,
534 if (lws_add_http_header_status(wsi, (unsigned int)code, p, end))