mirror of
https://github.com/matrix-construct/construct
synced 2025-01-19 19:11:53 +01:00
ircd:Ⓜ️:v1: IO'ing buffers must be on ctx's stack.
This commit is contained in:
parent
4c26b65613
commit
f26410f5c3
1 changed files with 6 additions and 12 deletions
18
ircd/m/v1.cc
18
ircd/m/v1.cc
|
@ -161,14 +161,11 @@ ircd::m::v1::backfill::backfill(const room::id &room_id,
|
||||||
if(!opts.remote)
|
if(!opts.remote)
|
||||||
opts.remote = room_id.host();
|
opts.remote = room_id.host();
|
||||||
|
|
||||||
|
m::event::id::buf event_id_buf;
|
||||||
if(!opts.event_id)
|
if(!opts.event_id)
|
||||||
{
|
{
|
||||||
thread_local m::event::id::buf event_id
|
event_id_buf = fetch_head(room_id, opts.remote);
|
||||||
{
|
opts.event_id = event_id_buf;
|
||||||
fetch_head(room_id, opts.remote)
|
|
||||||
};
|
|
||||||
|
|
||||||
opts.event_id = event_id;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!defined(json::get<"origin"_>(opts.request)))
|
if(!defined(json::get<"origin"_>(opts.request)))
|
||||||
|
@ -236,14 +233,11 @@ ircd::m::v1::state::state(const room::id &room_id,
|
||||||
if(!opts.remote)
|
if(!opts.remote)
|
||||||
opts.remote = room_id.host();
|
opts.remote = room_id.host();
|
||||||
|
|
||||||
|
m::event::id::buf event_id_buf;
|
||||||
if(!opts.event_id)
|
if(!opts.event_id)
|
||||||
{
|
{
|
||||||
thread_local m::event::id::buf event_id
|
event_id_buf = fetch_head(room_id, opts.remote);
|
||||||
{
|
opts.event_id = event_id_buf;
|
||||||
fetch_head(room_id, opts.remote)
|
|
||||||
};
|
|
||||||
|
|
||||||
opts.event_id = event_id;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!defined(json::get<"origin"_>(opts.request)))
|
if(!defined(json::get<"origin"_>(opts.request)))
|
||||||
|
|
Loading…
Add table
Reference in a new issue