diff options
author | Glenn Strauss <gstrauss@gluelogic.com> | 2021-06-20 11:21:14 -0400 |
---|---|---|
committer | Glenn Strauss <gstrauss@gluelogic.com> | 2021-08-27 02:16:54 -0400 |
commit | 9fe8fbaa72451ebdbfa1a30c73a5e4f37f6dc205 (patch) | |
tree | 239299be90eaad965c9c98fe867aae853cabceb0 /src/configfile-glue.c | |
parent | 1de03a03ee03e3d715b51319752a52b23114e6f6 (diff) | |
download | lighttpd-git-9fe8fbaa72451ebdbfa1a30c73a5e4f37f6dc205.tar.gz |
[multiple] http_method_buf()
- http_method_buf() returns (const buffer *)
- comment out unused get_http_status_name()
- inline func for http_append_method()
config processing requires a persistent buffer for method on the
off-chance that the config performed a capturing regex match in
$HTTP["method"] condition and used it later (e.g. in mod_rewrite)
(Prior behavior using r->tmp_buf was undefined in this case)
Diffstat (limited to 'src/configfile-glue.c')
-rw-r--r-- | src/configfile-glue.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/src/configfile-glue.c b/src/configfile-glue.c index e0588c92..6bf1fbf7 100644 --- a/src/configfile-glue.c +++ b/src/configfile-glue.c @@ -541,12 +541,7 @@ static cond_result_t config_check_cond_nocache(request_st * const r, const data_ if (NULL == l) l = (buffer *)&empty_string; break; case COMP_HTTP_REQUEST_METHOD: - { - buffer * const tb = r->tmp_buf; - l = tb; - buffer_clear(tb); - http_method_append(tb, r->http_method); - } + l = http_method_buf(r->http_method); break; default: return COND_RESULT_FALSE; |