mirror of
https://github.com/RGBCube/serenity
synced 2025-06-01 09:28:13 +00:00
AK/ByteBuffer+Everywhere: Handle errors in ByteBuffer::slice()
This commit is contained in:
parent
c0486f93d4
commit
c10d48b72c
12 changed files with 45 additions and 34 deletions
|
@ -85,7 +85,8 @@ public:
|
|||
{
|
||||
auto length = m_current_length;
|
||||
m_current_length = 0;
|
||||
return m_packet_data.slice(0, length);
|
||||
// FIXME: Propagate errors.
|
||||
return MUST(m_packet_data.slice(0, length));
|
||||
}
|
||||
inline void set(size_t offset, u8 value)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue