LibCrypto: This method wrote to a const pointer.
This commit is contained in:
parent
7f70a6f0cb
commit
68cf22d580
Notes:
sideshowbarker
2024-07-19 04:33:08 +09:00
Author: https://github.com/asynts Commit: https://github.com/SerenityOS/serenity/commit/68cf22d580a Pull-request: https://github.com/SerenityOS/serenity/pull/2903
2 changed files with 4 additions and 2 deletions
|
@ -67,8 +67,9 @@ public:
|
|||
static SignedBigInteger import_data(const u8* ptr, size_t length);
|
||||
|
||||
size_t export_data(AK::ByteBuffer& data) const;
|
||||
size_t export_data(const u8* ptr, size_t length) const
|
||||
size_t export_data(u8* ptr, size_t length) const
|
||||
{
|
||||
// Note: ByteBuffer::wrap() does a const_cast!
|
||||
auto buffer = ByteBuffer::wrap(ptr, length);
|
||||
return export_data(buffer);
|
||||
}
|
||||
|
|
|
@ -59,8 +59,9 @@ public:
|
|||
}
|
||||
|
||||
size_t export_data(AK::ByteBuffer& data) const;
|
||||
size_t export_data(const u8* ptr, size_t length) const
|
||||
size_t export_data(u8* ptr, size_t length) const
|
||||
{
|
||||
// Note: ByteBuffer::wrap() does a const_cast!
|
||||
auto buffer = ByteBuffer::wrap(ptr, length);
|
||||
return export_data(buffer);
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue