`SERENITYOS` is also set when compiling Lagom on SerenityOS, so we can't
just check it and expect `CMAKE_STAGING_PREFIX` to be set.
Instead, check `CMAKE_STAGING_PREFIX` directly and use that as an
indicator for whether we can install a file there.
This was accidentally broken in
ac40197047, after which we started
installing headers into a `LibCrypt` subdirectory instead.
`serenity_install_headers("")` is really the only thing that we need
from `serenity_libc`, so just replicate that manually.
This fix addresses issue where, if request headers contain
"Connection: keep-alive", we keep socket open without letting client
know that we support keep-alive connections. This can result in a
large number of open and unused sockets.
Before this change `apply_clip_overflow_rect` might crash trying to
access `clip_rect` that does not have value because we currently
support calculation of visible rectangle when `overflow: hidden`
is applied for both axis.
The deallocation of the test cases at the very end happens through a
NonnullRefPtr<TestCase>, meaning the deallocation will assume the wrong
object size and trip up ASAN. Therefore, we cannot use a TestCase
subclass.
I also took this opportunity and made use of the new LoaderError
formatter.
This is a special case of the sample count field in the header which we
treated as a format error before. Now we just take care to check stream
EOF before reading chunks.
This makes the final FLAC spec test pass, making us one of the most
compliant loaders! :^)
We report a rounded up PCM sample format to the outside, but use the
exact bit depth as specified in header and frames.
This makes the three FLAC spec tests with a a bit depth of 20 pass.
Fix the problem that `cmake --build Build/ladybird` started
failing with:
fatal error: 'WebContent/WebDriverConnection.h' file not found
after 11fe34ce0f
Previously it was possible to have following sequence of calls
while destroying a session:
1. `WebContentConnection::die()` calls `Client::close_session()`
2. `Client::close_session()` removes a session from active sessions
map which causes session destructor call.
3. Session destructor calls `Client::close_session()` to remove a
session from active sessions.
With `stop()` method inlined into destructor `close_session()` need
to be called just once while destroying a session.
As the user might want to have interactions with LibGUI while handling
errors, this code should be executed in the original `EventLoop`.
Similarly to what is done with the error-free path.
"Improve" is an understatement, since this commit makes all FLAC files
seek without errors, mostly with high accuracy, and partially even fast:
- A new generic seek table type is introduced, which keeps an
always-sorted list of seek points, which allows it to use binary
search and fast insertion.
- Automatic seek points are inserted according to two heuristics
(distance between seek points and minimum seek precision), which not
only builds a seek table for already-played sections of the file, but
improves seek precision even for files with an existing seek table.
- Manual seeking by skipping frames works properly now and is still used
as a last resort.
It appears that QEMU on macOS doesn't have the VirtIO GPU variants that
support VGA functionality. Those variants are not especially important
to us, because we don't use any kind of VGA functionality in our kernel
anyway.
Therefore, for macOS, we could decide to use virtio-gpu-gl-pci and
virtio-gpu-pci devices instead.
It appeared that we sometimes failed to invoke synchronous commands on
the GPU. To temporarily fix this, wait 10 milliseconds for commands to
complete before failing.
According to the specification, modesetting can be invoked with no need
for flushing the framebuffer nor with DMA to transfer the framebuffer
rendering.
This configuration exposes a suboptimal mechanism to access other
VirtIO device configurations. It is also the only configuration to use a
zero length for a configuration structure, and specify a valid BAR which
triggered a kernel panic when attaching a virtio-gpu-pci device before
95b15e4901 was applied.
The real solution for that problem is to ignore this configuration type
because we never actually use it. It means that we can VERIFY that all
other configuration types have a valid length, as being expected.