mirror of
https://codeberg.org/grunfink/snac2.git
synced 2024-11-14 17:45:04 +00:00
Propagate the caching headers.
This commit is contained in:
parent
eb6d3d0d0e
commit
7dc42f5b3b
1 changed files with 6 additions and 0 deletions
6
html.c
6
html.c
|
@ -3221,6 +3221,12 @@ int html_get_handler(const xs_dict *req, const char *q_path,
|
|||
|
||||
hdrs = xs_dict_append(hdrs, "user-agent", USER_AGENT);
|
||||
|
||||
const char *ims = xs_dict_get(req, "if-modified-since");
|
||||
const char *inm = xs_dict_get(req, "if-none-match");
|
||||
|
||||
if (ims) hdrs = xs_dict_append(hdrs, "if-modified-since", ims);
|
||||
if (inm) hdrs = xs_dict_append(hdrs, "if-none-match", inm);
|
||||
|
||||
xs *rsp = xs_http_request("GET", url, hdrs,
|
||||
NULL, 0, &status, body, b_size, 0);
|
||||
|
||||
|
|
Loading…
Reference in a new issue