diff options
author | Andreas Kling <kling@serenityos.org> | 2021-11-11 01:06:34 +0100 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-11-11 01:27:46 +0100 |
commit | 80d4e830a0a95a41e3a3a6ccdc938fdfc4c7430b (patch) | |
tree | 80482418dd76af80034d5dc215db51c12ce27f67 /Userland/Libraries/LibCore | |
parent | 8b1108e4858f797c9216dc8ae4a3918ad50c73b4 (diff) | |
download | serenity-80d4e830a0a95a41e3a3a6ccdc938fdfc4c7430b.zip |
Everywhere: Pass AK::ReadonlyBytes by value
Diffstat (limited to 'Userland/Libraries/LibCore')
-rw-r--r-- | Userland/Libraries/LibCore/MimeData.cpp | 2 | ||||
-rw-r--r-- | Userland/Libraries/LibCore/MimeData.h | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/Userland/Libraries/LibCore/MimeData.cpp b/Userland/Libraries/LibCore/MimeData.cpp index e6cbe8a5ef..10ca8a7eee 100644 --- a/Userland/Libraries/LibCore/MimeData.cpp +++ b/Userland/Libraries/LibCore/MimeData.cpp @@ -137,7 +137,7 @@ String guess_mime_type_based_on_filename(StringView path) ENUMERATE_HEADER_CONTENTS #undef __ENUMERATE_MIME_TYPE_HEADER -Optional<String> guess_mime_type_based_on_sniffed_bytes(const ReadonlyBytes& bytes) +Optional<String> guess_mime_type_based_on_sniffed_bytes(ReadonlyBytes bytes) { #define __ENUMERATE_MIME_TYPE_HEADER(var_name, mime_type, pattern_offset, pattern_size, ...) \ if (static_cast<ssize_t>(bytes.size()) >= pattern_offset && bytes.slice(pattern_offset).starts_with(var_name)) \ diff --git a/Userland/Libraries/LibCore/MimeData.h b/Userland/Libraries/LibCore/MimeData.h index 852b9bdad6..cdaf8686d0 100644 --- a/Userland/Libraries/LibCore/MimeData.h +++ b/Userland/Libraries/LibCore/MimeData.h @@ -49,6 +49,6 @@ private: String guess_mime_type_based_on_filename(StringView); -Optional<String> guess_mime_type_based_on_sniffed_bytes(const ReadonlyBytes&); +Optional<String> guess_mime_type_based_on_sniffed_bytes(ReadonlyBytes); } |