mirror of
https://github.com/matrix-construct/construct
synced 2024-11-29 10:12:39 +01:00
ircd:Ⓜ️ Use better constexpr for room_id() stack buffer size.
This commit is contained in:
parent
fad454f3b1
commit
65f87b58bc
1 changed files with 4 additions and 2 deletions
|
@ -2782,14 +2782,16 @@ ircd::m::count_since(const room &r,
|
|||
ircd::m::id::room::buf
|
||||
ircd::m::room_id(const id::room_alias &room_alias)
|
||||
{
|
||||
char buf[256];
|
||||
char buf[m::id::MAX_SIZE + 1];
|
||||
static_assert(sizeof(buf) <= 256);
|
||||
return room_id(buf, room_alias);
|
||||
}
|
||||
|
||||
ircd::m::id::room::buf
|
||||
ircd::m::room_id(const string_view &room_id_or_alias)
|
||||
{
|
||||
char buf[256];
|
||||
char buf[m::id::MAX_SIZE + 1];
|
||||
static_assert(sizeof(buf) <= 256);
|
||||
return room_id(buf, room_id_or_alias);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue