mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 19:47:44 +00:00
Meta+LibC through LibHTTP: Make clang-format-10 clean
Why break at LibHTTP? Because "Meta+Libraries" would be insanely large, and breaking between LibHTTP and LibJS makes the commits roughly evenly large.
This commit is contained in:
parent
64cc3f51d0
commit
ede5dbd7b3
58 changed files with 87 additions and 89 deletions
|
@ -37,7 +37,7 @@ __BEGIN_DECLS
|
|||
const char* inet_ntop(int af, const void* src, char* dst, socklen_t);
|
||||
int inet_pton(int af, const char* src, void* dst);
|
||||
|
||||
static inline int inet_aton(const char *cp, struct in_addr *inp)
|
||||
static inline int inet_aton(const char* cp, struct in_addr* inp)
|
||||
{
|
||||
return inet_pton(AF_INET, cp, inp);
|
||||
}
|
||||
|
|
|
@ -32,8 +32,8 @@
|
|||
#include <stdlib.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
#include <AK/LexicalPath.h>
|
||||
#include <AK/HashMap.h>
|
||||
#include <AK/LexicalPath.h>
|
||||
#include <AK/RefPtr.h>
|
||||
#include <AK/ScopeGuard.h>
|
||||
#include <AK/String.h>
|
||||
|
@ -85,7 +85,8 @@ void* dlopen(const char* filename, int flags)
|
|||
|
||||
ScopeGuard close_fd_guard([fd]() { close(fd); });
|
||||
|
||||
struct stat file_stats{};
|
||||
struct stat file_stats {
|
||||
};
|
||||
|
||||
int ret = fstat(fd, &file_stats);
|
||||
if (ret < 0) {
|
||||
|
|
|
@ -26,8 +26,8 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
#include <stddef.h>
|
||||
#include <sys/cdefs.h>
|
||||
|
||||
__BEGIN_DECLS
|
||||
|
||||
|
|
|
@ -29,7 +29,7 @@
|
|||
#include <bits/stdint.h>
|
||||
|
||||
#ifndef PAGE_SIZE
|
||||
#define PAGE_SIZE 4096
|
||||
# define PAGE_SIZE 4096
|
||||
#endif
|
||||
|
||||
#define PATH_MAX 4096
|
||||
|
|
|
@ -43,7 +43,7 @@
|
|||
//#define MALLOC_DEBUG
|
||||
#define RECYCLE_BIG_ALLOCATIONS
|
||||
|
||||
#define MAGIC_PAGE_HEADER 0x42657274 // 'Bert'
|
||||
#define MAGIC_PAGE_HEADER 0x42657274 // 'Bert'
|
||||
#define MAGIC_BIGALLOC_HEADER 0x42697267 // 'Birg'
|
||||
#define PAGE_ROUND_UP(x) ((((size_t)(x)) + PAGE_SIZE - 1) & (~(PAGE_SIZE - 1)))
|
||||
|
||||
|
|
|
@ -28,4 +28,3 @@
|
|||
|
||||
#define MALLOC_SCRUB_BYTE 0xdc
|
||||
#define FREE_SCRUB_BYTE 0xed
|
||||
|
||||
|
|
|
@ -26,9 +26,9 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
#include <bits/stdint.h>
|
||||
#include <signal.h>
|
||||
#include <stdbool.h>
|
||||
#include <bits/stdint.h>
|
||||
#include <sys/cdefs.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
|
|
|
@ -64,7 +64,7 @@ struct sigaction {
|
|||
int kill(pid_t, int sig);
|
||||
int killpg(int pgrp, int sig);
|
||||
sighandler_t signal(int sig, sighandler_t);
|
||||
int pthread_sigmask(int how, const sigset_t *set, sigset_t *ol_dset);
|
||||
int pthread_sigmask(int how, const sigset_t* set, sigset_t* ol_dset);
|
||||
int sigaction(int sig, const struct sigaction* act, struct sigaction* old_act);
|
||||
int sigemptyset(sigset_t*);
|
||||
int sigfillset(sigset_t*);
|
||||
|
|
|
@ -34,14 +34,14 @@
|
|||
|
||||
#include <spawn.h>
|
||||
|
||||
#include <AK/Function.h>
|
||||
#include <AK/Vector.h>
|
||||
#include <fcntl.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <unistd.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/types.h>
|
||||
#include <AK/Function.h>
|
||||
#include <AK/Vector.h>
|
||||
#include <unistd.h>
|
||||
|
||||
struct posix_spawn_file_actions_state {
|
||||
Vector<Function<int()>, 4> actions;
|
||||
|
@ -286,5 +286,4 @@ int posix_spawnattr_setsigmask(posix_spawnattr_t* attr, const sigset_t* sigmask)
|
|||
attr->sigmask = *sigmask;
|
||||
return 0;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -28,13 +28,13 @@
|
|||
|
||||
#ifndef KERNEL
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
# include <sys/cdefs.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
# define NULL nullptr
|
||||
#else
|
||||
# define NULL ((void*)0)
|
||||
#endif
|
||||
# ifdef __cplusplus
|
||||
# define NULL nullptr
|
||||
# else
|
||||
# define NULL ((void*)0)
|
||||
# endif
|
||||
|
||||
typedef __PTRDIFF_TYPE__ ptrdiff_t;
|
||||
typedef __SIZE_TYPE__ size_t;
|
||||
|
|
|
@ -28,9 +28,9 @@
|
|||
|
||||
#define _STDIO_H // Make GMP believe we exist.
|
||||
|
||||
#include <bits/FILE.h>
|
||||
#include <limits.h>
|
||||
#include <stdarg.h>
|
||||
#include <bits/FILE.h>
|
||||
#include <sys/cdefs.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue