0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-11-26 00:32:35 +01:00

ircd::server: Rename opts member pointer to opt.

This commit is contained in:
Jason Volk 2018-03-07 07:21:00 -08:00
parent 90528245de
commit 9b44217ea4
2 changed files with 10 additions and 10 deletions

View file

@ -92,12 +92,12 @@ struct ircd::server::request
server::in in;
/// Options
const struct opts *opts { &opts_default };
const opts *opt { &opts_default };
request(const net::hostport &,
server::out,
server::in,
const struct opts *const & = nullptr);
const opts *const & = nullptr);
request() = default;
request(request &&) noexcept;
@ -126,11 +126,11 @@ inline
ircd::server::request::request(const net::hostport &hostport,
server::out out,
server::in in,
const struct opts *const &opts)
const opts *const &opt)
:tag{nullptr}
,out{std::move(out)}
,in{std::move(in)}
,opts{opts?: &opts_default}
,opt{opt?: &opts_default}
{
submit(hostport, *this);
}
@ -142,7 +142,7 @@ noexcept
,tag{std::move(o.tag)}
,out{std::move(o.out)}
,in{std::move(o.in)}
,opts{std::move(o.opts)}
,opt{std::move(o.opt)}
{
if(tag)
associate(*this, *tag, std::move(o));
@ -160,7 +160,7 @@ noexcept
out = std::move(o.out);
in = std::move(o.in);
tag = std::move(o.tag);
opts = std::move(o.opts);
opt = std::move(o.opt);
if(tag)
associate(*this, *tag, std::move(o));

View file

@ -2116,10 +2116,10 @@ ircd::server::tag::read_head(const const_buffer &buffer,
if(dynamic)
{
assert(req.opts);
assert(req.opt);
const size_t alloc_size
{
std::min(head.content_length, req.opts->content_length_maxalloc)
std::min(head.content_length, req.opt->content_length_maxalloc)
};
req.in.dynamic = unique_buffer<mutable_buffer>{alloc_size};
@ -2274,8 +2274,8 @@ ircd::server::tag::set_value(args&&... a)
std::forward<args>(a)...
};
assert(request->opts);
if(request->opts->http_exceptions && code >= http::code(300))
assert(request->opt);
if(request->opt->http_exceptions && code >= http::code(300))
{
const string_view content
{