diff options
| author | 2023-01-12 09:28:02 +0100 | |
|---|---|---|
| committer | 2023-01-12 09:28:02 +0100 | |
| commit | bb0d8f2a2755af5e11b46d32be84155ba71ea534 (patch) | |
| tree | 86eb998f66c875dc7d2d40ba3021a3e69ffe9400 /xs_httpd.h | |
| parent | Show the More... link above the 'About this site'. (diff) | |
| download | penes-snac2-bb0d8f2a2755af5e11b46d32be84155ba71ea534.tar.gz penes-snac2-bb0d8f2a2755af5e11b46d32be84155ba71ea534.tar.xz penes-snac2-bb0d8f2a2755af5e11b46d32be84155ba71ea534.zip | |
Backport from xs.
Diffstat (limited to 'xs_httpd.h')
| -rw-r--r-- | xs_httpd.h | 6 |
1 files changed, 3 insertions, 3 deletions
| @@ -185,7 +185,7 @@ d_char *xs_httpd_request(FILE *f, d_char **payload, int *p_size) | |||
| 185 | xs_socket_timeout(fileno(f), 2.0, 0.0); | 185 | xs_socket_timeout(fileno(f), 2.0, 0.0); |
| 186 | 186 | ||
| 187 | /* read the first line and split it */ | 187 | /* read the first line and split it */ |
| 188 | l1 = xs_strip(xs_readline(f)); | 188 | l1 = xs_strip_i(xs_readline(f)); |
| 189 | l2 = xs_split(l1, " "); | 189 | l2 = xs_split(l1, " "); |
| 190 | 190 | ||
| 191 | if (xs_list_len(l2) != 3) { | 191 | if (xs_list_len(l2) != 3) { |
| @@ -214,7 +214,7 @@ d_char *xs_httpd_request(FILE *f, d_char **payload, int *p_size) | |||
| 214 | for (;;) { | 214 | for (;;) { |
| 215 | xs *l, *p = NULL; | 215 | xs *l, *p = NULL; |
| 216 | 216 | ||
| 217 | l = xs_strip(xs_readline(f)); | 217 | l = xs_strip_i(xs_readline(f)); |
| 218 | 218 | ||
| 219 | /* done with the header? */ | 219 | /* done with the header? */ |
| 220 | if (strcmp(l, "") == 0) | 220 | if (strcmp(l, "") == 0) |
| @@ -224,7 +224,7 @@ d_char *xs_httpd_request(FILE *f, d_char **payload, int *p_size) | |||
| 224 | p = xs_split_n(l, ": ", 1); | 224 | p = xs_split_n(l, ": ", 1); |
| 225 | 225 | ||
| 226 | if (xs_list_len(p) == 2) | 226 | if (xs_list_len(p) == 2) |
| 227 | req = xs_dict_append(req, xs_tolower(xs_list_get(p, 0)), xs_list_get(p, 1)); | 227 | req = xs_dict_append(req, xs_tolower_i(xs_list_get(p, 0)), xs_list_get(p, 1)); |
| 228 | } | 228 | } |
| 229 | 229 | ||
| 230 | xs_socket_timeout(fileno(f), 5.0, 0.0); | 230 | xs_socket_timeout(fileno(f), 5.0, 0.0); |