Everywhere: Run clang-format

The following command was used to clang-format these files:

    clang-format-19 -i $(find . \
        -not \( -path "./\.*" -prune \) \
        -not \( -path "./Build/*" -prune \) \
        -not \( -path "./Toolchain/*" -prune \) \
        -type f -name "*.cpp" -o -name "*.mm" -o -name "*.h")
This commit is contained in:
Timothy Flynn 2024-12-27 18:47:33 -05:00 committed by Tim Flynn
commit 27478ec7d4
Notes: github-actions[bot] 2024-12-28 13:40:37 +00:00
57 changed files with 160 additions and 140 deletions

View file

@ -69,7 +69,7 @@ ErrorOr<void> Command::write_lines(Span<ByteString> lines)
// It's possible the process dies before we can write everything to the
// stdin. So make sure that we don't crash but just stop writing.
struct sigaction action_handler { };
struct sigaction action_handler {};
action_handler.sa_handler = SIG_IGN;
struct sigaction old_action_handler;

View file

@ -286,7 +286,7 @@ ErrorOr<bool> Process::is_being_debugged()
if (sysctl(mib, sizeof(mib) / sizeof(*mib), &info, &size, NULL, 0) < 0)
return Error::from_syscall("sysctl"sv, -errno);
// We're being debugged if the P_TRACED flag is set.
// We're being debugged if the P_TRACED flag is set.
# if defined(AK_OS_MACOS)
return ((info.kp_proc.p_flag & P_TRACED) != 0);
# elif defined(AK_OS_FREEBSD)

View file

@ -111,7 +111,7 @@ public:
// Set the callback to be called when the promise is rejected. Setting this callback
// will cause the promise fulfillment to be ready to be handled.
template<CallableAs<void, ErrorType&&> RejectedHandler>
ThreadedPromise& when_rejected(RejectedHandler when_rejected = [](ErrorType&) {})
ThreadedPromise& when_rejected(RejectedHandler when_rejected = [](ErrorType&) { })
{
Threading::MutexLocker locker { m_mutex };
VERIFY(!m_rejection_handler);