mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-21 23:20:20 +00:00
Everywhere: Fix many spelling errors
This commit is contained in:
parent
6bf91d00ef
commit
3102d8e160
Notes:
sideshowbarker
2024-07-17 21:30:09 +09:00
Author: https://github.com/mjz19910 Commit: https://github.com/SerenityOS/serenity/commit/3102d8e160b Pull-request: https://github.com/SerenityOS/serenity/pull/11666 Reviewed-by: https://github.com/creator1creeper1 Reviewed-by: https://github.com/linusg ✅
39 changed files with 73 additions and 73 deletions
|
@ -96,14 +96,14 @@ public:
|
||||||
bool unreliable_eof() const override { return eof(); }
|
bool unreliable_eof() const override { return eof(); }
|
||||||
bool eof() const { return m_queue.size() == 0; }
|
bool eof() const { return m_queue.size() == 0; }
|
||||||
|
|
||||||
size_t remaining_contigous_space() const
|
size_t remaining_contiguous_space() const
|
||||||
{
|
{
|
||||||
return min(Capacity - m_queue.size(), m_queue.capacity() - (m_queue.head_index() + m_queue.size()) % Capacity);
|
return min(Capacity - m_queue.size(), m_queue.capacity() - (m_queue.head_index() + m_queue.size()) % Capacity);
|
||||||
}
|
}
|
||||||
|
|
||||||
Bytes reserve_contigous_space(size_t count)
|
Bytes reserve_contiguous_space(size_t count)
|
||||||
{
|
{
|
||||||
VERIFY(count <= remaining_contigous_space());
|
VERIFY(count <= remaining_contiguous_space());
|
||||||
|
|
||||||
Bytes bytes { m_queue.m_storage + (m_queue.head_index() + m_queue.size()) % Capacity, count };
|
Bytes bytes { m_queue.m_storage + (m_queue.head_index() + m_queue.size()) % Capacity, count };
|
||||||
|
|
||||||
|
|
|
@ -129,7 +129,7 @@ public:
|
||||||
return !this->m_value;
|
return !this->m_value;
|
||||||
}
|
}
|
||||||
// Intentionally don't define `operator bool() const` here. C++ is a bit
|
// Intentionally don't define `operator bool() const` here. C++ is a bit
|
||||||
// overzealos, and whenever there would be a type error, C++ instead tries
|
// overzealous, and whenever there would be a type error, C++ instead tries
|
||||||
// to convert to a common int-ish type first. `bool` is int-ish, so
|
// to convert to a common int-ish type first. `bool` is int-ish, so
|
||||||
// `operator bool() const` would defy the entire point of this class.
|
// `operator bool() const` would defy the entire point of this class.
|
||||||
|
|
||||||
|
|
|
@ -47,7 +47,7 @@ classes of common C++ errors, including memory leaks, out of bounds access to st
|
||||||
signed integer overflow. For more info on the sanitizers, check out the Address Sanitizer [wiki page](https://github.com/google/sanitizers/wiki),
|
signed integer overflow. For more info on the sanitizers, check out the Address Sanitizer [wiki page](https://github.com/google/sanitizers/wiki),
|
||||||
or the Undefined Sanitizer [documentation](https://clang.llvm.org/docs/UndefinedBehaviorSanitizer.html) from clang.
|
or the Undefined Sanitizer [documentation](https://clang.llvm.org/docs/UndefinedBehaviorSanitizer.html) from clang.
|
||||||
|
|
||||||
Note that a sanitizer build will take significantly longer than a non-santizer build, and will mess with caches in tools such as `ccache`.
|
Note that a sanitizer build will take significantly longer than a non-sanitizer build, and will mess with caches in tools such as `ccache`.
|
||||||
The sanitizers can be enabled with the `-DENABLE_FOO_SANITIZER` set of flags. For the Serenity target, only the Undefined Sanitizers is supported.
|
The sanitizers can be enabled with the `-DENABLE_FOO_SANITIZER` set of flags. For the Serenity target, only the Undefined Sanitizers is supported.
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
|
|
|
@ -88,7 +88,7 @@ These extensions can be used as-is, but you need to point them to the custom Ser
|
||||||
```
|
```
|
||||||
</details>
|
</details>
|
||||||
|
|
||||||
Most nonsentical errors from the extension also involve not finding methods, types etc.
|
Most nonsensical errors from the extension also involve not finding methods, types etc.
|
||||||
|
|
||||||
### DSL syntax highlighting
|
### DSL syntax highlighting
|
||||||
|
|
||||||
|
@ -337,7 +337,7 @@ The following snippet may be useful if you want to quickly generate a license he
|
||||||
" * SPDX-License-Identifier: BSD-2-Clause",
|
" * SPDX-License-Identifier: BSD-2-Clause",
|
||||||
" */"
|
" */"
|
||||||
],
|
],
|
||||||
"description": "Licence header"
|
"description": "License header"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
|
@ -47,7 +47,7 @@ static constexpr u16 UHCI_FRAMELIST_FRAME_INVALID = 0x0001;
|
||||||
|
|
||||||
// Port stuff
|
// Port stuff
|
||||||
static constexpr u8 UHCI_ROOT_PORT_COUNT = 2;
|
static constexpr u8 UHCI_ROOT_PORT_COUNT = 2;
|
||||||
static constexpr u16 UHCI_PORTSC_CURRRENT_CONNECT_STATUS = 0x0001;
|
static constexpr u16 UHCI_PORTSC_CURRENT_CONNECT_STATUS = 0x0001;
|
||||||
static constexpr u16 UHCI_PORTSC_CONNECT_STATUS_CHANGED = 0x0002;
|
static constexpr u16 UHCI_PORTSC_CONNECT_STATUS_CHANGED = 0x0002;
|
||||||
static constexpr u16 UHCI_PORTSC_PORT_ENABLED = 0x0004;
|
static constexpr u16 UHCI_PORTSC_PORT_ENABLED = 0x0004;
|
||||||
static constexpr u16 UHCI_PORTSC_PORT_ENABLE_CHANGED = 0x0008;
|
static constexpr u16 UHCI_PORTSC_PORT_ENABLE_CHANGED = 0x0008;
|
||||||
|
@ -56,7 +56,7 @@ static constexpr u16 UHCI_PORTSC_RESUME_DETECT = 0x40;
|
||||||
static constexpr u16 UHCI_PORTSC_LOW_SPEED_DEVICE = 0x0100;
|
static constexpr u16 UHCI_PORTSC_LOW_SPEED_DEVICE = 0x0100;
|
||||||
static constexpr u16 UHCI_PORTSC_PORT_RESET = 0x0200;
|
static constexpr u16 UHCI_PORTSC_PORT_RESET = 0x0200;
|
||||||
static constexpr u16 UHCI_PORTSC_SUSPEND = 0x1000;
|
static constexpr u16 UHCI_PORTSC_SUSPEND = 0x1000;
|
||||||
static constexpr u16 UCHI_PORTSC_NON_WRITE_CLEAR_BIT_MASK = 0x1FF5; // This is used to mask out the Write Clear bits making sure we don't accidentally clear them.
|
static constexpr u16 UHCI_PORTSC_NON_WRITE_CLEAR_BIT_MASK = 0x1FF5; // This is used to mask out the Write Clear bits making sure we don't accidentally clear them.
|
||||||
|
|
||||||
// *BSD and a few other drivers seem to use this number
|
// *BSD and a few other drivers seem to use this number
|
||||||
static constexpr u8 UHCI_NUMBER_OF_ISOCHRONOUS_TDS = 128;
|
static constexpr u8 UHCI_NUMBER_OF_ISOCHRONOUS_TDS = 128;
|
||||||
|
@ -511,7 +511,7 @@ void UHCIController::get_port_status(Badge<UHCIRootHub>, u8 port, HubStatus& hub
|
||||||
|
|
||||||
u16 status = port == 0 ? read_portsc1() : read_portsc2();
|
u16 status = port == 0 ? read_portsc1() : read_portsc2();
|
||||||
|
|
||||||
if (status & UHCI_PORTSC_CURRRENT_CONNECT_STATUS)
|
if (status & UHCI_PORTSC_CURRENT_CONNECT_STATUS)
|
||||||
hub_port_status.status |= PORT_STATUS_CURRENT_CONNECT_STATUS;
|
hub_port_status.status |= PORT_STATUS_CURRENT_CONNECT_STATUS;
|
||||||
|
|
||||||
if (status & UHCI_PORTSC_CONNECT_STATUS_CHANGED)
|
if (status & UHCI_PORTSC_CONNECT_STATUS_CHANGED)
|
||||||
|
@ -555,7 +555,7 @@ void UHCIController::reset_port(u8 port)
|
||||||
VERIFY(port < NUMBER_OF_ROOT_PORTS);
|
VERIFY(port < NUMBER_OF_ROOT_PORTS);
|
||||||
|
|
||||||
u16 port_data = port == 0 ? read_portsc1() : read_portsc2();
|
u16 port_data = port == 0 ? read_portsc1() : read_portsc2();
|
||||||
port_data &= UCHI_PORTSC_NON_WRITE_CLEAR_BIT_MASK;
|
port_data &= UHCI_PORTSC_NON_WRITE_CLEAR_BIT_MASK;
|
||||||
port_data |= UHCI_PORTSC_PORT_RESET;
|
port_data |= UHCI_PORTSC_PORT_RESET;
|
||||||
if (port == 0)
|
if (port == 0)
|
||||||
write_portsc1(port_data);
|
write_portsc1(port_data);
|
||||||
|
@ -605,7 +605,7 @@ ErrorOr<void> UHCIController::set_port_feature(Badge<UHCIRootHub>, u8 port, HubF
|
||||||
break;
|
break;
|
||||||
case HubFeatureSelector::PORT_SUSPEND: {
|
case HubFeatureSelector::PORT_SUSPEND: {
|
||||||
u16 port_data = port == 0 ? read_portsc1() : read_portsc2();
|
u16 port_data = port == 0 ? read_portsc1() : read_portsc2();
|
||||||
port_data &= UCHI_PORTSC_NON_WRITE_CLEAR_BIT_MASK;
|
port_data &= UHCI_PORTSC_NON_WRITE_CLEAR_BIT_MASK;
|
||||||
port_data |= UHCI_PORTSC_SUSPEND;
|
port_data |= UHCI_PORTSC_SUSPEND;
|
||||||
|
|
||||||
if (port == 0)
|
if (port == 0)
|
||||||
|
@ -632,7 +632,7 @@ ErrorOr<void> UHCIController::clear_port_feature(Badge<UHCIRootHub>, u8 port, Hu
|
||||||
dbgln_if(UHCI_DEBUG, "UHCI: clear_port_feature: port={} feature_selector={}", port, (u8)feature_selector);
|
dbgln_if(UHCI_DEBUG, "UHCI: clear_port_feature: port={} feature_selector={}", port, (u8)feature_selector);
|
||||||
|
|
||||||
u16 port_data = port == 0 ? read_portsc1() : read_portsc2();
|
u16 port_data = port == 0 ? read_portsc1() : read_portsc2();
|
||||||
port_data &= UCHI_PORTSC_NON_WRITE_CLEAR_BIT_MASK;
|
port_data &= UHCI_PORTSC_NON_WRITE_CLEAR_BIT_MASK;
|
||||||
|
|
||||||
switch (feature_selector) {
|
switch (feature_selector) {
|
||||||
case HubFeatureSelector::PORT_ENABLE:
|
case HubFeatureSelector::PORT_ENABLE:
|
||||||
|
|
|
@ -730,16 +730,16 @@ ErrorOr<size_t> Plan9FSInode::read_bytes(off_t offset, size_t size, UserOrKernel
|
||||||
StringView data;
|
StringView data;
|
||||||
|
|
||||||
// Try readlink first.
|
// Try readlink first.
|
||||||
bool readlink_succeded = false;
|
bool readlink_succeeded = false;
|
||||||
if (fs().m_remote_protocol_version >= Plan9FS::ProtocolVersion::v9P2000L && offset == 0) {
|
if (fs().m_remote_protocol_version >= Plan9FS::ProtocolVersion::v9P2000L && offset == 0) {
|
||||||
message << fid();
|
message << fid();
|
||||||
if (auto result = fs().post_message_and_wait_for_a_reply(message); !result.is_error()) {
|
if (auto result = fs().post_message_and_wait_for_a_reply(message); !result.is_error()) {
|
||||||
readlink_succeded = true;
|
readlink_succeeded = true;
|
||||||
message >> data;
|
message >> data;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!readlink_succeded) {
|
if (!readlink_succeeded) {
|
||||||
message = Plan9FS::Message { fs(), Plan9FS::Message::Type::Tread };
|
message = Plan9FS::Message { fs(), Plan9FS::Message::Type::Tread };
|
||||||
message << fid() << (u64)offset << (u32)size;
|
message << fid() << (u64)offset << (u32)size;
|
||||||
TRY(fs().post_message_and_wait_for_a_reply(message));
|
TRY(fs().post_message_and_wait_for_a_reply(message));
|
||||||
|
|
|
@ -86,7 +86,7 @@ UNMAP_AFTER_INIT void BIOSSysFSDirectory::set_dmi_32_bit_entry_initialization_va
|
||||||
auto smbios_entry = Memory::map_typed<SMBIOS::EntryPoint32bit>(m_dmi_entry_point, SMBIOS_SEARCH_AREA_SIZE);
|
auto smbios_entry = Memory::map_typed<SMBIOS::EntryPoint32bit>(m_dmi_entry_point, SMBIOS_SEARCH_AREA_SIZE);
|
||||||
m_smbios_structure_table = PhysicalAddress(smbios_entry.ptr()->legacy_structure.smbios_table_ptr);
|
m_smbios_structure_table = PhysicalAddress(smbios_entry.ptr()->legacy_structure.smbios_table_ptr);
|
||||||
m_dmi_entry_point_length = smbios_entry.ptr()->length;
|
m_dmi_entry_point_length = smbios_entry.ptr()->length;
|
||||||
m_smbios_structure_table_length = smbios_entry.ptr()->legacy_structure.smboios_table_length;
|
m_smbios_structure_table_length = smbios_entry.ptr()->legacy_structure.smbios_table_length;
|
||||||
}
|
}
|
||||||
|
|
||||||
UNMAP_AFTER_INIT NonnullRefPtr<BIOSSysFSDirectory> BIOSSysFSDirectory::must_create(FirmwareSysFSDirectory& firmware_directory)
|
UNMAP_AFTER_INIT NonnullRefPtr<BIOSSysFSDirectory> BIOSSysFSDirectory::must_create(FirmwareSysFSDirectory& firmware_directory)
|
||||||
|
|
|
@ -23,7 +23,7 @@ namespace Kernel::SMBIOS {
|
||||||
struct [[gnu::packed]] LegacyEntryPoint32bit {
|
struct [[gnu::packed]] LegacyEntryPoint32bit {
|
||||||
char legacy_sig[5];
|
char legacy_sig[5];
|
||||||
u8 checksum2;
|
u8 checksum2;
|
||||||
u16 smboios_table_length;
|
u16 smbios_table_length;
|
||||||
u32 smbios_table_ptr;
|
u32 smbios_table_ptr;
|
||||||
u16 smbios_tables_count;
|
u16 smbios_tables_count;
|
||||||
u8 smbios_bcd_revision;
|
u8 smbios_bcd_revision;
|
||||||
|
|
|
@ -161,7 +161,7 @@ void PIC::remap(u8 offset)
|
||||||
IO::out8(PIC0_CTL, ICW1_INIT | ICW1_ICW4);
|
IO::out8(PIC0_CTL, ICW1_INIT | ICW1_ICW4);
|
||||||
IO::out8(PIC1_CTL, ICW1_INIT | ICW1_ICW4);
|
IO::out8(PIC1_CTL, ICW1_INIT | ICW1_ICW4);
|
||||||
|
|
||||||
/* ICW2 (upper 5 bits specify ISR indices, lower 3 idunno) */
|
/* ICW2 (upper 5 bits specify ISR indices, lower 3 don't specify anything) */
|
||||||
IO::out8(PIC0_CMD, offset);
|
IO::out8(PIC0_CMD, offset);
|
||||||
IO::out8(PIC1_CMD, offset + 0x08);
|
IO::out8(PIC1_CMD, offset + 0x08);
|
||||||
|
|
||||||
|
@ -188,7 +188,7 @@ UNMAP_AFTER_INIT void PIC::initialize()
|
||||||
IO::out8(PIC0_CTL, ICW1_INIT | ICW1_ICW4);
|
IO::out8(PIC0_CTL, ICW1_INIT | ICW1_ICW4);
|
||||||
IO::out8(PIC1_CTL, ICW1_INIT | ICW1_ICW4);
|
IO::out8(PIC1_CTL, ICW1_INIT | ICW1_ICW4);
|
||||||
|
|
||||||
/* ICW2 (upper 5 bits specify ISR indices, lower 3 idunno) */
|
/* ICW2 (upper 5 bits specify ISR indices, lower 3 don't specify anything) */
|
||||||
IO::out8(PIC0_CMD, IRQ_VECTOR_BASE);
|
IO::out8(PIC0_CMD, IRQ_VECTOR_BASE);
|
||||||
IO::out8(PIC1_CMD, IRQ_VECTOR_BASE + 0x08);
|
IO::out8(PIC1_CMD, IRQ_VECTOR_BASE + 0x08);
|
||||||
|
|
||||||
|
|
|
@ -710,7 +710,7 @@ ErrorOr<void> Process::send_signal(u8 signal, Process* sender)
|
||||||
// If the main thread has died, there may still be other threads:
|
// If the main thread has died, there may still be other threads:
|
||||||
if (!receiver_thread) {
|
if (!receiver_thread) {
|
||||||
// The first one should be good enough.
|
// The first one should be good enough.
|
||||||
// Neither kill(2) nor kill(3) specify any selection precedure.
|
// Neither kill(2) nor kill(3) specify any selection procedure.
|
||||||
for_each_thread([&receiver_thread](Thread& thread) -> IterationDecision {
|
for_each_thread([&receiver_thread](Thread& thread) -> IterationDecision {
|
||||||
receiver_thread = &thread;
|
receiver_thread = &thread;
|
||||||
return IterationDecision::Break;
|
return IterationDecision::Break;
|
||||||
|
|
|
@ -99,17 +99,17 @@ time_t now()
|
||||||
};
|
};
|
||||||
|
|
||||||
unsigned year, month, day, hour, minute, second;
|
unsigned year, month, day, hour, minute, second;
|
||||||
bool did_read_rtc_sucessfully = false;
|
bool did_read_rtc_successfully = false;
|
||||||
for (size_t attempt = 0; attempt < 5; attempt++) {
|
for (size_t attempt = 0; attempt < 5; attempt++) {
|
||||||
if (!try_to_read_registers(year, month, day, hour, minute, second))
|
if (!try_to_read_registers(year, month, day, hour, minute, second))
|
||||||
break;
|
break;
|
||||||
if (check_registers_against_preloaded_values(year, month, day, hour, minute, second)) {
|
if (check_registers_against_preloaded_values(year, month, day, hour, minute, second)) {
|
||||||
did_read_rtc_sucessfully = true;
|
did_read_rtc_successfully = true;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
dmesgln("RTC: {} Year: {}, month: {}, day: {}, hour: {}, minute: {}, second: {}", (did_read_rtc_sucessfully ? "" : "(failed to read)"), year, month, day, hour, minute, second);
|
dmesgln("RTC: {} Year: {}, month: {}, day: {}, hour: {}, minute: {}, second: {}", (did_read_rtc_successfully ? "" : "(failed to read)"), year, month, day, hour, minute, second);
|
||||||
|
|
||||||
time_t days_since_epoch = years_to_days_since_epoch(year) + day_of_year(year, month, day);
|
time_t days_since_epoch = years_to_days_since_epoch(year) + day_of_year(year, month, day);
|
||||||
return ((days_since_epoch * 24 + hour) * 60 + minute) * 60 + second;
|
return ((days_since_epoch * 24 + hour) * 60 + minute) * 60 + second;
|
||||||
|
|
|
@ -19,7 +19,7 @@ Result<NonnullOwnPtr<MBRPartitionTable>, PartitionTable::Error> MBRPartitionTabl
|
||||||
{
|
{
|
||||||
auto table = make<MBRPartitionTable>(device);
|
auto table = make<MBRPartitionTable>(device);
|
||||||
if (table->contains_ebr())
|
if (table->contains_ebr())
|
||||||
return { PartitionTable::Error::ConatinsEBR };
|
return { PartitionTable::Error::ContainsEBR };
|
||||||
if (table->is_protective_mbr())
|
if (table->is_protective_mbr())
|
||||||
return { PartitionTable::Error::MBRProtective };
|
return { PartitionTable::Error::MBRProtective };
|
||||||
if (!table->is_valid())
|
if (!table->is_valid())
|
||||||
|
|
|
@ -19,7 +19,7 @@ public:
|
||||||
enum class Error {
|
enum class Error {
|
||||||
Invalid,
|
Invalid,
|
||||||
MBRProtective,
|
MBRProtective,
|
||||||
ConatinsEBR,
|
ContainsEBR,
|
||||||
};
|
};
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
|
@ -101,7 +101,7 @@ UNMAP_AFTER_INIT OwnPtr<PartitionTable> StorageManagement::try_to_initialize_par
|
||||||
return {};
|
return {};
|
||||||
return move(gpt_table_or_result.value());
|
return move(gpt_table_or_result.value());
|
||||||
}
|
}
|
||||||
if (mbr_table_or_result.error() == PartitionTable::Error::ConatinsEBR) {
|
if (mbr_table_or_result.error() == PartitionTable::Error::ContainsEBR) {
|
||||||
auto ebr_table_or_result = EBRPartitionTable::try_to_initialize(device);
|
auto ebr_table_or_result = EBRPartitionTable::try_to_initialize(device);
|
||||||
if (ebr_table_or_result.is_error())
|
if (ebr_table_or_result.is_error())
|
||||||
return {};
|
return {};
|
||||||
|
|
|
@ -1762,7 +1762,7 @@ JS::ThrowCompletionOr<bool> @class_name@::is_named_property_exposed_on_object(JS
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
// 2. If O has an own property named P, then return false.
|
// 2. If O has an own property named P, then return false.
|
||||||
// NOTE: This has to be done manually instead of using Object::has_own_property, as that would use the overrided internal_get_own_property.
|
// NOTE: This has to be done manually instead of using Object::has_own_property, as that would use the overridden internal_get_own_property.
|
||||||
auto own_property_named_p = MUST(Object::internal_get_own_property(property_name));
|
auto own_property_named_p = MUST(Object::internal_get_own_property(property_name));
|
||||||
|
|
||||||
if (own_property_named_p.has_value())
|
if (own_property_named_p.has_value())
|
||||||
|
@ -2198,7 +2198,7 @@ JS::ThrowCompletionOr<bool> @class_name@::internal_define_own_property(JS::Prope
|
||||||
// 2. If O implements an interface with the [LegacyOverrideBuiltIns] extended attribute or O does not have an own property named P, then:
|
// 2. If O implements an interface with the [LegacyOverrideBuiltIns] extended attribute or O does not have an own property named P, then:
|
||||||
if (!interface.extended_attributes.contains("LegacyOverrideBuiltIns")) {
|
if (!interface.extended_attributes.contains("LegacyOverrideBuiltIns")) {
|
||||||
scoped_generator.append(R"~~~(
|
scoped_generator.append(R"~~~(
|
||||||
// NOTE: This has to be done manually instead of using Object::has_own_property, as that would use the overrided internal_get_own_property.
|
// NOTE: This has to be done manually instead of using Object::has_own_property, as that would use the overridden internal_get_own_property.
|
||||||
auto own_property_named_p = TRY(Object::internal_get_own_property(property_name));
|
auto own_property_named_p = TRY(Object::internal_get_own_property(property_name));
|
||||||
|
|
||||||
if (!own_property_named_p.has_value()))~~~");
|
if (!own_property_named_p.has_value()))~~~");
|
||||||
|
|
|
@ -908,8 +908,8 @@ TEST_CASE(optimizer_atomic_groups)
|
||||||
Tuple { "(abcfoo|abcbar|abcbaz).*x"sv, "abcbarx"sv, true },
|
Tuple { "(abcfoo|abcbar|abcbaz).*x"sv, "abcbarx"sv, true },
|
||||||
Tuple { "(a|a)"sv, "a"sv, true },
|
Tuple { "(a|a)"sv, "a"sv, true },
|
||||||
Tuple { "(a|)"sv, ""sv, true }, // Ensure that empty alternatives are not outright removed
|
Tuple { "(a|)"sv, ""sv, true }, // Ensure that empty alternatives are not outright removed
|
||||||
Tuple { "a{2,3}|a{5,8}"sv, "abc"sv, false }, // Optimiser should not mess up the instruction stream by ignoring inter-insn dependencies, see #11247.
|
Tuple { "a{2,3}|a{5,8}"sv, "abc"sv, false }, // Optimizer should not mess up the instruction stream by ignoring inter-insn dependencies, see #11247.
|
||||||
Tuple { "^(a{2,3}|a{5,8})$"sv, "aaaa"sv, false }, // Optimiser should not mess up the instruction stream by ignoring inter-insn dependencies, see #11247.
|
Tuple { "^(a{2,3}|a{5,8})$"sv, "aaaa"sv, false }, // Optimizer should not mess up the instruction stream by ignoring inter-insn dependencies, see #11247.
|
||||||
// ForkReplace shouldn't be applied where it would change the semantics
|
// ForkReplace shouldn't be applied where it would change the semantics
|
||||||
Tuple { "(1+)\\1"sv, "11"sv, true },
|
Tuple { "(1+)\\1"sv, "11"sv, true },
|
||||||
Tuple { "(1+)1"sv, "11"sv, true },
|
Tuple { "(1+)1"sv, "11"sv, true },
|
||||||
|
|
|
@ -20,7 +20,7 @@
|
||||||
* [ ] switch to use tsc values for perf check
|
* [ ] switch to use tsc values for perf check
|
||||||
* [ ] handle mouse events differently for smoother painting (queue)
|
* [ ] handle mouse events differently for smoother painting (queue)
|
||||||
* [ ] handle fire bitmap edges better
|
* [ ] handle fire bitmap edges better
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <LibCore/ElapsedTimer.h>
|
#include <LibCore/ElapsedTimer.h>
|
||||||
#include <LibCore/System.h>
|
#include <LibCore/System.h>
|
||||||
|
@ -107,7 +107,7 @@ Fire::Fire()
|
||||||
bitmap->scanline_u8(bitmap->height() - 1)[i] = FIRE_MAX;
|
bitmap->scanline_u8(bitmap->height() - 1)[i] = FIRE_MAX;
|
||||||
|
|
||||||
/* Set off initital paint event */
|
/* Set off initital paint event */
|
||||||
//update();
|
// update();
|
||||||
}
|
}
|
||||||
|
|
||||||
Fire::~Fire()
|
Fire::~Fire()
|
||||||
|
@ -134,7 +134,7 @@ void Fire::timer_event(Core::TimerEvent&)
|
||||||
if (phase > 1)
|
if (phase > 1)
|
||||||
phase = 0;
|
phase = 0;
|
||||||
|
|
||||||
/* Paint our palettized buffer to screen */
|
/* Paint our palletized buffer to screen */
|
||||||
for (int px = 0 + phase; px < FIRE_WIDTH; px += 2) {
|
for (int px = 0 + phase; px < FIRE_WIDTH; px += 2) {
|
||||||
for (int py = 1; py < FIRE_HEIGHT; py++) {
|
for (int py = 1; py < FIRE_HEIGHT; py++) {
|
||||||
int rnd = rand() % 3;
|
int rnd = rand() % 3;
|
||||||
|
|
|
@ -176,13 +176,13 @@ void ServerConnectionWrapper::on_crash()
|
||||||
dbgln("LanguageServer crash frequency is too high");
|
dbgln("LanguageServer crash frequency is too high");
|
||||||
m_respawn_allowed = false;
|
m_respawn_allowed = false;
|
||||||
|
|
||||||
show_frequenct_crashes_notification();
|
show_frequent_crashes_notification();
|
||||||
} else {
|
} else {
|
||||||
m_last_crash_timer.start();
|
m_last_crash_timer.start();
|
||||||
try_respawn_connection();
|
try_respawn_connection();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
void ServerConnectionWrapper::show_frequenct_crashes_notification() const
|
void ServerConnectionWrapper::show_frequent_crashes_notification() const
|
||||||
{
|
{
|
||||||
auto notification = GUI::Notification::construct();
|
auto notification = GUI::Notification::construct();
|
||||||
notification->set_icon(Gfx::Bitmap::try_load_from_file("/res/icons/32x32/app-hack-studio.png").release_value_but_fixme_should_propagate_errors());
|
notification->set_icon(Gfx::Bitmap::try_load_from_file("/res/icons/32x32/app-hack-studio.png").release_value_but_fixme_should_propagate_errors());
|
||||||
|
|
|
@ -78,7 +78,7 @@ public:
|
||||||
private:
|
private:
|
||||||
void create_connection();
|
void create_connection();
|
||||||
void show_crash_notification() const;
|
void show_crash_notification() const;
|
||||||
void show_frequenct_crashes_notification() const;
|
void show_frequent_crashes_notification() const;
|
||||||
|
|
||||||
Language m_language;
|
Language m_language;
|
||||||
Function<NonnullRefPtr<ServerConnection>()> m_connection_creator;
|
Function<NonnullRefPtr<ServerConnection>()> m_connection_creator;
|
||||||
|
|
|
@ -366,10 +366,10 @@ MaybeLoaderError FlacLoaderPlugin::next_frame(Span<Sample> target_vector)
|
||||||
Sample frame = { left[i] / sample_rescale, right[i] / sample_rescale };
|
Sample frame = { left[i] / sample_rescale, right[i] / sample_rescale };
|
||||||
target_vector[i] = frame;
|
target_vector[i] = frame;
|
||||||
}
|
}
|
||||||
// move superflous data into the class buffer instead
|
// move superfluous data into the class buffer instead
|
||||||
auto result = m_unread_data.try_grow_capacity(m_current_frame->sample_count - samples_to_directly_copy);
|
auto result = m_unread_data.try_grow_capacity(m_current_frame->sample_count - samples_to_directly_copy);
|
||||||
if (result.is_error())
|
if (result.is_error())
|
||||||
return LoaderError { LoaderError::Category::Internal, static_cast<size_t>(samples_to_directly_copy + m_current_sample_or_frame), "Couldn't allocate sample buffer for superflous data" };
|
return LoaderError { LoaderError::Category::Internal, static_cast<size_t>(samples_to_directly_copy + m_current_sample_or_frame), "Couldn't allocate sample buffer for superfluous data" };
|
||||||
|
|
||||||
for (size_t i = samples_to_directly_copy; i < m_current_frame->sample_count; ++i) {
|
for (size_t i = samples_to_directly_copy; i < m_current_frame->sample_count; ++i) {
|
||||||
Sample frame = { left[i] / sample_rescale, right[i] / sample_rescale };
|
Sample frame = { left[i] / sample_rescale, right[i] / sample_rescale };
|
||||||
|
@ -630,7 +630,7 @@ ErrorOr<Vector<i32>, LoaderError> FlacLoaderPlugin::decode_custom_lpc(FlacSubfra
|
||||||
for (size_t t = 0; t < subframe.order; ++t) {
|
for (size_t t = 0; t < subframe.order; ++t) {
|
||||||
// It's really important that we compute in 64-bit land here.
|
// It's really important that we compute in 64-bit land here.
|
||||||
// Even though FLAC operates at a maximum bit depth of 32 bits, modern encoders use super-large coefficients for maximum compression.
|
// Even though FLAC operates at a maximum bit depth of 32 bits, modern encoders use super-large coefficients for maximum compression.
|
||||||
// These will easily overflow 32 bits and cause strange white noise that apruptly stops intermittently (at the end of a frame).
|
// These will easily overflow 32 bits and cause strange white noise that abruptly stops intermittently (at the end of a frame).
|
||||||
// The simple fix of course is to do intermediate computations in 64 bits.
|
// The simple fix of course is to do intermediate computations in 64 bits.
|
||||||
sample += static_cast<i64>(coefficients[t]) * static_cast<i64>(decoded[i - t - 1]);
|
sample += static_cast<i64>(coefficients[t]) * static_cast<i64>(decoded[i - t - 1]);
|
||||||
}
|
}
|
||||||
|
|
|
@ -180,10 +180,10 @@ bool DeflateDecompressor::UncompressedBlock::try_read_more()
|
||||||
if (m_bytes_remaining == 0)
|
if (m_bytes_remaining == 0)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
const auto nread = min(m_bytes_remaining, m_decompressor.m_output_stream.remaining_contigous_space());
|
const auto nread = min(m_bytes_remaining, m_decompressor.m_output_stream.remaining_contiguous_space());
|
||||||
m_bytes_remaining -= nread;
|
m_bytes_remaining -= nread;
|
||||||
|
|
||||||
m_decompressor.m_input_stream >> m_decompressor.m_output_stream.reserve_contigous_space(nread);
|
m_decompressor.m_input_stream >> m_decompressor.m_output_stream.reserve_contiguous_space(nread);
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
|
@ -435,7 +435,7 @@ size_t EventLoop::pump(WaitMode mode)
|
||||||
void EventLoop::post_event(Object& receiver, NonnullOwnPtr<Event>&& event)
|
void EventLoop::post_event(Object& receiver, NonnullOwnPtr<Event>&& event)
|
||||||
{
|
{
|
||||||
Threading::MutexLocker lock(m_private->lock);
|
Threading::MutexLocker lock(m_private->lock);
|
||||||
dbgln_if(EVENTLOOP_DEBUG, "Core::EventLoop::post_event: ({}) << receivier={}, event={}", m_queued_events.size(), receiver, event);
|
dbgln_if(EVENTLOOP_DEBUG, "Core::EventLoop::post_event: ({}) << receiver={}, event={}", m_queued_events.size(), receiver, event);
|
||||||
m_queued_events.empend(receiver, move(event));
|
m_queued_events.empend(receiver, move(event));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -522,7 +522,7 @@ void EventLoop::handle_signal(int signo)
|
||||||
VERIFY(signo != 0);
|
VERIFY(signo != 0);
|
||||||
// We MUST check if the current pid still matches, because there
|
// We MUST check if the current pid still matches, because there
|
||||||
// is a window between fork() and exec() where a signal delivered
|
// is a window between fork() and exec() where a signal delivered
|
||||||
// to our fork could be inadvertedly routed to the parent process!
|
// to our fork could be inadvertently routed to the parent process!
|
||||||
if (getpid() == s_pid) {
|
if (getpid() == s_pid) {
|
||||||
int nwritten = write(s_wake_pipe_fds[1], &signo, sizeof(signo));
|
int nwritten = write(s_wake_pipe_fds[1], &signo, sizeof(signo));
|
||||||
if (nwritten < 0) {
|
if (nwritten < 0) {
|
||||||
|
|
|
@ -183,7 +183,7 @@ done_parsing:;
|
||||||
if (offset_hours.has_value() || offset_minutes.has_value())
|
if (offset_hours.has_value() || offset_minutes.has_value())
|
||||||
dbgln("FIXME: Implement GeneralizedTime with offset!");
|
dbgln("FIXME: Implement GeneralizedTime with offset!");
|
||||||
|
|
||||||
// Unceremonially drop the milliseconds on the floor.
|
// Unceremoniously drop the milliseconds on the floor.
|
||||||
return Core::DateTime::create(year.value(), month.value(), day.value(), hour.value(), minute.value_or(0), seconds.value_or(0));
|
return Core::DateTime::create(year.value(), month.value(), day.value(), hour.value(), minute.value_or(0), seconds.value_or(0));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -383,7 +383,7 @@ void pretty_print(Decoder& decoder, OutputStream& stream, int indent)
|
||||||
}
|
}
|
||||||
case Kind::Sequence:
|
case Kind::Sequence:
|
||||||
case Kind::Set:
|
case Kind::Set:
|
||||||
dbgln("Seq/Sequence PrettyPrint error: Unexpected Primtive");
|
dbgln("Seq/Sequence PrettyPrint error: Unexpected Primitive");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -142,7 +142,7 @@ void UnsignedBigIntegerAlgorithms::almost_montgomery_multiplication_without_allo
|
||||||
UnsignedBigInteger::Word t = z.m_words[i] * k;
|
UnsignedBigInteger::Word t = z.m_words[i] * k;
|
||||||
UnsignedBigInteger::Word carry_2 = montgomery_fragment(z, i, modulo, t, num_words);
|
UnsignedBigInteger::Word carry_2 = montgomery_fragment(z, i, modulo, t, num_words);
|
||||||
|
|
||||||
// Compute the carry by combining all of the carrys of the previous computations
|
// Compute the carry by combining all of the carries of the previous computations
|
||||||
// Put it "right after" the range that we computed above
|
// Put it "right after" the range that we computed above
|
||||||
UnsignedBigInteger::Word temp_carry = previous_double_carry + carry_1;
|
UnsignedBigInteger::Word temp_carry = previous_double_carry + carry_1;
|
||||||
UnsignedBigInteger::Word overall_carry = temp_carry + carry_2;
|
UnsignedBigInteger::Word overall_carry = temp_carry + carry_2;
|
||||||
|
|
|
@ -104,7 +104,7 @@ OwnPtr<DebugSession> DebugSession::exec_and_attach(String const& command,
|
||||||
return {};
|
return {};
|
||||||
}
|
}
|
||||||
|
|
||||||
// We want to continue until the exit from the 'execve' sycsall.
|
// We want to continue until the exit from the 'execve' syscall.
|
||||||
// This ensures that when we start debugging the process
|
// This ensures that when we start debugging the process
|
||||||
// it executes the target image, and not the forked image of the tracing process.
|
// it executes the target image, and not the forked image of the tracing process.
|
||||||
// NOTE: we only need to do this when we are debugging a new process (i.e not attaching to a process that's already running!)
|
// NOTE: we only need to do this when we are debugging a new process (i.e not attaching to a process that's already running!)
|
||||||
|
|
|
@ -144,7 +144,7 @@ private:
|
||||||
HashMap<void*, BreakPoint> m_breakpoints;
|
HashMap<void*, BreakPoint> m_breakpoints;
|
||||||
HashMap<void*, WatchPoint> m_watchpoints;
|
HashMap<void*, WatchPoint> m_watchpoints;
|
||||||
|
|
||||||
// Maps from library name to LoadedLibrary obect
|
// Maps from library name to LoadedLibrary object
|
||||||
HashMap<String, NonnullOwnPtr<LoadedLibrary>> m_loaded_libraries;
|
HashMap<String, NonnullOwnPtr<LoadedLibrary>> m_loaded_libraries;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -245,7 +245,7 @@ void DebugSession::run(DesiredInitialDebugeeState initial_debugee_state, Callbac
|
||||||
if (current_breakpoint.has_value()) {
|
if (current_breakpoint.has_value()) {
|
||||||
// We want to make the breakpoint transparent to the user of the debugger.
|
// We want to make the breakpoint transparent to the user of the debugger.
|
||||||
// To achieve this, we perform two rollbacks:
|
// To achieve this, we perform two rollbacks:
|
||||||
// 1. Set regs.eip to point at the actual address of the instruction we breaked on.
|
// 1. Set regs.eip to point at the actual address of the instruction we broke on.
|
||||||
// regs.eip currently points to one byte after the address of the original instruction,
|
// regs.eip currently points to one byte after the address of the original instruction,
|
||||||
// because the cpu has just executed the INT3 we patched into the instruction.
|
// because the cpu has just executed the INT3 we patched into the instruction.
|
||||||
// 2. We restore the original first byte of the instruction,
|
// 2. We restore the original first byte of the instruction,
|
||||||
|
@ -285,9 +285,9 @@ void DebugSession::run(DesiredInitialDebugeeState initial_debugee_state, Callbac
|
||||||
// To re-enable the breakpoint, we first perform a single step and execute the
|
// To re-enable the breakpoint, we first perform a single step and execute the
|
||||||
// instruction of the breakpoint, and then redo the INT3 patch in its first byte.
|
// instruction of the breakpoint, and then redo the INT3 patch in its first byte.
|
||||||
|
|
||||||
// If the user manually inserted a breakpoint at were we breaked at originally,
|
// If the user manually inserted a breakpoint at the current instruction,
|
||||||
// we need to disable that breakpoint because we want to singlestep over it to execute the
|
// we need to disable that breakpoint because we want to singlestep over that
|
||||||
// instruction we breaked on (we re-enable it again later anyways).
|
// instruction (we re-enable it again later anyways).
|
||||||
if (m_breakpoints.contains(current_breakpoint.value().address) && m_breakpoints.get(current_breakpoint.value().address).value().state == BreakPointState::Enabled) {
|
if (m_breakpoints.contains(current_breakpoint.value().address) && m_breakpoints.get(current_breakpoint.value().address).value().state == BreakPointState::Enabled) {
|
||||||
disable_breakpoint(current_breakpoint.value().address);
|
disable_breakpoint(current_breakpoint.value().address);
|
||||||
}
|
}
|
||||||
|
|
|
@ -247,7 +247,7 @@ void LineProgram::handle_standard_opcode(u8 opcode)
|
||||||
m_basic_block = true;
|
m_basic_block = true;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case StandardOpcodes::SetProlougeEnd: {
|
case StandardOpcodes::SetPrologueEnd: {
|
||||||
m_prologue_end = true;
|
m_prologue_end = true;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
|
@ -153,7 +153,7 @@ private:
|
||||||
SetBasicBlock,
|
SetBasicBlock,
|
||||||
ConstAddPc,
|
ConstAddPc,
|
||||||
FixAdvancePc,
|
FixAdvancePc,
|
||||||
SetProlougeEnd,
|
SetPrologueEnd,
|
||||||
SetEpilogueBegin,
|
SetEpilogueBegin,
|
||||||
SetIsa
|
SetIsa
|
||||||
};
|
};
|
||||||
|
|
|
@ -714,7 +714,7 @@ static ErrorOr<void> decode_png_bitmap(PNGLoadingContext& context)
|
||||||
return Error::from_string_literal("PNGImageDecoderPlugin: Didn't see an IHDR chunk."sv);
|
return Error::from_string_literal("PNGImageDecoderPlugin: Didn't see an IHDR chunk."sv);
|
||||||
|
|
||||||
if (context.color_type == 3 && context.palette_data.is_empty())
|
if (context.color_type == 3 && context.palette_data.is_empty())
|
||||||
return Error::from_string_literal("PNGImageDecoderPlugin: Didn't see a PLTE chunk for a palettized image, or it was empty."sv);
|
return Error::from_string_literal("PNGImageDecoderPlugin: Didn't see a PLTE chunk for a palletized image, or it was empty."sv);
|
||||||
|
|
||||||
auto result = Compress::Zlib::decompress_all(context.compressed_data.span());
|
auto result = Compress::Zlib::decompress_all(context.compressed_data.span());
|
||||||
if (!result.has_value()) {
|
if (!result.has_value()) {
|
||||||
|
|
|
@ -1164,7 +1164,7 @@ void TryStatement::generate_bytecode(Bytecode::Generator& generator) const
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
[&](NonnullRefPtr<BindingPattern> const&) {
|
[&](NonnullRefPtr<BindingPattern> const&) {
|
||||||
// FIXME: Implement this path when the above DeclrativeEnvironment issue is dealt with.
|
// FIXME: Implement this path when the above DeclarativeEnvironment issue is dealt with.
|
||||||
TODO();
|
TODO();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -106,8 +106,8 @@ Optional<Certificate> Certificate::parse_asn1(ReadonlyBytes buffer, bool)
|
||||||
// validity Validity,
|
// validity Validity,
|
||||||
// subject Name,
|
// subject Name,
|
||||||
// subject_public_key_info SubjectPublicKeyInfo,
|
// subject_public_key_info SubjectPublicKeyInfo,
|
||||||
// issuer_unique_id (1) IMPLICIT UniqueIdentifer OPTIONAL (if present, version > v1),
|
// issuer_unique_id (1) IMPLICIT UniqueIdentifier OPTIONAL (if present, version > v1),
|
||||||
// subject_unique_id (2) IMPLICIT UniqueIdentiier OPTIONAL (if present, version > v1),
|
// subject_unique_id (2) IMPLICIT UniqueIdentifier OPTIONAL (if present, version > v1),
|
||||||
// extensions (3) EXPLICIT Extensions OPTIONAL (if present, version > v2)
|
// extensions (3) EXPLICIT Extensions OPTIONAL (if present, version > v2)
|
||||||
// }
|
// }
|
||||||
ENTER_SCOPE_OR_FAIL(Sequence, "Certificate::TBSCertificate");
|
ENTER_SCOPE_OR_FAIL(Sequence, "Certificate::TBSCertificate");
|
||||||
|
@ -413,7 +413,7 @@ Optional<Certificate> Certificate::parse_asn1(ReadonlyBytes buffer, bool)
|
||||||
case 3:
|
case 3:
|
||||||
// x400Address
|
// x400Address
|
||||||
// We don't know how to use this.
|
// We don't know how to use this.
|
||||||
DROP_OBJECT_OR_FAIL("Certificate::TBSCertificate::Extensions::$::Extension::extension_value::SubjectAlternativeName::$::X400Adress");
|
DROP_OBJECT_OR_FAIL("Certificate::TBSCertificate::Extensions::$::Extension::extension_value::SubjectAlternativeName::$::X400Address");
|
||||||
break;
|
break;
|
||||||
case 4:
|
case 4:
|
||||||
// Directory name
|
// Directory name
|
||||||
|
|
|
@ -187,7 +187,7 @@ void TLSv12::update_packet(ByteBuffer& packet)
|
||||||
// copy the header over
|
// copy the header over
|
||||||
ct.overwrite(0, packet.data(), header_size - 2);
|
ct.overwrite(0, packet.data(), header_size - 2);
|
||||||
|
|
||||||
// get the appropricate HMAC value for the entire packet
|
// get the appropriate HMAC value for the entire packet
|
||||||
auto mac = hmac_message(packet, {}, mac_size, true);
|
auto mac = hmac_message(packet, {}, mac_size, true);
|
||||||
|
|
||||||
// write the MAC
|
// write the MAC
|
||||||
|
|
|
@ -174,7 +174,7 @@ void TLSv12::try_disambiguate_error() const
|
||||||
|
|
||||||
void TLSv12::set_root_certificates(Vector<Certificate> certificates)
|
void TLSv12::set_root_certificates(Vector<Certificate> certificates)
|
||||||
{
|
{
|
||||||
if (!m_context.root_ceritificates.is_empty())
|
if (!m_context.root_certificates.is_empty())
|
||||||
dbgln("TLS warn: resetting root certificates!");
|
dbgln("TLS warn: resetting root certificates!");
|
||||||
|
|
||||||
for (auto& cert : certificates) {
|
for (auto& cert : certificates) {
|
||||||
|
@ -182,7 +182,7 @@ void TLSv12::set_root_certificates(Vector<Certificate> certificates)
|
||||||
dbgln("Certificate for {} by {} is invalid, things may or may not work!", cert.subject.subject, cert.issuer.subject);
|
dbgln("Certificate for {} by {} is invalid, things may or may not work!", cert.subject.subject, cert.issuer.subject);
|
||||||
// FIXME: Figure out what we should do when our root certs are invalid.
|
// FIXME: Figure out what we should do when our root certs are invalid.
|
||||||
}
|
}
|
||||||
m_context.root_ceritificates = move(certificates);
|
m_context.root_certificates = move(certificates);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool Context::verify_chain() const
|
bool Context::verify_chain() const
|
||||||
|
@ -202,7 +202,7 @@ bool Context::verify_chain() const
|
||||||
HashMap<String, String> chain;
|
HashMap<String, String> chain;
|
||||||
HashTable<String> roots;
|
HashTable<String> roots;
|
||||||
// First, walk the root certs.
|
// First, walk the root certs.
|
||||||
for (auto& cert : root_ceritificates) {
|
for (auto& cert : root_certificates) {
|
||||||
roots.set(cert.subject.subject);
|
roots.set(cert.subject.subject);
|
||||||
chain.set(cert.subject.subject, cert.issuer.subject);
|
chain.set(cert.subject.subject, cert.issuer.subject);
|
||||||
}
|
}
|
||||||
|
|
|
@ -295,7 +295,7 @@ struct Context {
|
||||||
// message flags
|
// message flags
|
||||||
u8 handshake_messages[11] { 0 };
|
u8 handshake_messages[11] { 0 };
|
||||||
ByteBuffer user_data;
|
ByteBuffer user_data;
|
||||||
Vector<Certificate> root_ceritificates;
|
Vector<Certificate> root_certificates;
|
||||||
|
|
||||||
Vector<String> alpn;
|
Vector<String> alpn;
|
||||||
StringView negotiated_alpn;
|
StringView negotiated_alpn;
|
||||||
|
|
|
@ -245,7 +245,7 @@ void BytecodeInterpreter::store_to_memory(Configuration& configuration, Instruct
|
||||||
dbgln("LibWasm: Memory access out of bounds (expected 0 <= {} and {} <= {})", instance_address, instance_address + data.size(), memory->size());
|
dbgln("LibWasm: Memory access out of bounds (expected 0 <= {} and {} <= {})", instance_address, instance_address + data.size(), memory->size());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
dbgln_if(WASM_TRACE_DEBUG, "tempoaray({}b) -> store({})", data.size(), instance_address);
|
dbgln_if(WASM_TRACE_DEBUG, "temporary({}b) -> store({})", data.size(), instance_address);
|
||||||
data.copy_to(memory->data().bytes().slice(instance_address, data.size()));
|
data.copy_to(memory->data().bytes().slice(instance_address, data.size()));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -849,10 +849,10 @@ ParseResult<MemorySection::Memory> MemorySection::Memory::parse(InputStream& str
|
||||||
ParseResult<MemorySection> MemorySection::parse(InputStream& stream)
|
ParseResult<MemorySection> MemorySection::parse(InputStream& stream)
|
||||||
{
|
{
|
||||||
ScopeLogger<WASM_BINPARSER_DEBUG> logger("MemorySection");
|
ScopeLogger<WASM_BINPARSER_DEBUG> logger("MemorySection");
|
||||||
auto memorys = parse_vector<Memory>(stream);
|
auto memories = parse_vector<Memory>(stream);
|
||||||
if (memorys.is_error())
|
if (memories.is_error())
|
||||||
return memorys.error();
|
return memories.error();
|
||||||
return MemorySection { memorys.release_value() };
|
return MemorySection { memories.release_value() };
|
||||||
}
|
}
|
||||||
|
|
||||||
ParseResult<Expression> Expression::parse(InputStream& stream)
|
ParseResult<Expression> Expression::parse(InputStream& stream)
|
||||||
|
|
|
@ -619,8 +619,8 @@ public:
|
||||||
public:
|
public:
|
||||||
static constexpr u8 section_id = 5;
|
static constexpr u8 section_id = 5;
|
||||||
|
|
||||||
explicit MemorySection(Vector<Memory> memorys)
|
explicit MemorySection(Vector<Memory> memories)
|
||||||
: m_memories(move(memorys))
|
: m_memories(move(memories))
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1038,7 +1038,7 @@ void WindowManager::start_menu_doubleclick(Window& window, MouseEvent const& eve
|
||||||
// This is a special case. Basically, we're trying to determine whether
|
// This is a special case. Basically, we're trying to determine whether
|
||||||
// double clicking on the window menu icon happened. In this case, the
|
// double clicking on the window menu icon happened. In this case, the
|
||||||
// WindowFrame only receives a MouseDown event, and since the window
|
// WindowFrame only receives a MouseDown event, and since the window
|
||||||
// menu popus up, it does not see the MouseUp event. But, if they subsequently
|
// menu pops up, it does not see the MouseUp event. But, if they subsequently
|
||||||
// click there again, the menu is closed and we receive a MouseUp event.
|
// click there again, the menu is closed and we receive a MouseUp event.
|
||||||
// So, in order to be able to detect a double click when a menu is being
|
// So, in order to be able to detect a double click when a menu is being
|
||||||
// opened by the MouseDown event, we need to consider the MouseDown event
|
// opened by the MouseDown event, we need to consider the MouseDown event
|
||||||
|
|
Loading…
Reference in a new issue