+1
-23
@@ -1,29 +1,7 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
#pragma once
|
||||
|
||||
#if !defined(HAS_FEATURE_MEMORY_SANITIZER)
|
||||
# if defined(__has_feature)
|
||||
# if __has_feature(memory_sanitizer)
|
||||
# define HAS_FEATURE_MEMORY_SANITIZER 1
|
||||
# endif
|
||||
# endif
|
||||
# if !defined(HAS_FEATURE_MEMORY_SANITIZER)
|
||||
# define HAS_FEATURE_MEMORY_SANITIZER 0
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#if !defined(HAS_FEATURE_ADDRESS_SANITIZER)
|
||||
# ifdef __SANITIZE_ADDRESS__
|
||||
# define HAS_FEATURE_ADDRESS_SANITIZER 1
|
||||
# elif defined(__has_feature)
|
||||
# if __has_feature(address_sanitizer)
|
||||
# define HAS_FEATURE_ADDRESS_SANITIZER 1
|
||||
# endif
|
||||
# endif
|
||||
# if !defined(HAS_FEATURE_ADDRESS_SANITIZER)
|
||||
# define HAS_FEATURE_ADDRESS_SANITIZER 0
|
||||
# endif
|
||||
#endif
|
||||
#include "time-util.h"
|
||||
|
||||
#define DEFAULT_RESTART_USEC (100*USEC_PER_MSEC)
|
||||
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
#pragma once
|
||||
|
||||
#include <errno.h>
|
||||
#include <stdbool.h>
|
||||
#include <string.h>
|
||||
|
||||
|
||||
@@ -254,6 +254,7 @@ typedef enum UserStorage UserStorage;
|
||||
|
||||
typedef struct Bitmap Bitmap;
|
||||
typedef struct BPFProgram BPFProgram;
|
||||
typedef struct BusObjectImplementation BusObjectImplementation;
|
||||
typedef struct CalendarSpec CalendarSpec;
|
||||
typedef struct Condition Condition;
|
||||
typedef struct ConfigSection ConfigSection;
|
||||
|
||||
+24
-1
@@ -1,9 +1,32 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
#pragma once
|
||||
|
||||
#include "constants.h"
|
||||
#include "macro-fundamental.h"
|
||||
|
||||
#if !defined(HAS_FEATURE_MEMORY_SANITIZER)
|
||||
# if defined(__has_feature)
|
||||
# if __has_feature(memory_sanitizer)
|
||||
# define HAS_FEATURE_MEMORY_SANITIZER 1
|
||||
# endif
|
||||
# endif
|
||||
# if !defined(HAS_FEATURE_MEMORY_SANITIZER)
|
||||
# define HAS_FEATURE_MEMORY_SANITIZER 0
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#if !defined(HAS_FEATURE_ADDRESS_SANITIZER)
|
||||
# ifdef __SANITIZE_ADDRESS__
|
||||
# define HAS_FEATURE_ADDRESS_SANITIZER 1
|
||||
# elif defined(__has_feature)
|
||||
# if __has_feature(address_sanitizer)
|
||||
# define HAS_FEATURE_ADDRESS_SANITIZER 1
|
||||
# endif
|
||||
# endif
|
||||
# if !defined(HAS_FEATURE_ADDRESS_SANITIZER)
|
||||
# define HAS_FEATURE_ADDRESS_SANITIZER 0
|
||||
# endif
|
||||
#endif
|
||||
|
||||
/* Note: on GCC "no_sanitize_address" is a function attribute only, on llvm it may also be applied to global
|
||||
* variables. We define a specific macro which knows this. Note that on GCC we don't need this decorator so much, since
|
||||
* our primary use case for this attribute is registration structures placed in named ELF sections which shall not be
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
|
||||
#include <getopt.h>
|
||||
#include <sys/socket.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "sd-messages.h"
|
||||
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
|
||||
#include <getopt.h>
|
||||
#include <stdio.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "sd-bus.h"
|
||||
|
||||
|
||||
@@ -20,7 +20,6 @@
|
||||
#include "process-util.h"
|
||||
#include "procfs-util.h"
|
||||
#include "sort-util.h"
|
||||
#include "strv.h"
|
||||
#include "terminal-util.h"
|
||||
#include "time-util.h"
|
||||
#include "virt.h"
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "conf-files.h"
|
||||
#include "constants.h"
|
||||
#include "copy.h"
|
||||
#include "fd-util.h"
|
||||
#include "fileio.h"
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
|
||||
#include <sys/stat.h>
|
||||
#include <sys/statvfs.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "coredump-vacuum.h"
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <elf.h>
|
||||
#include <stdio.h>
|
||||
#include <sys/auxv.h>
|
||||
#include <sys/mount.h>
|
||||
#include <sys/prctl.h>
|
||||
#include <sys/statvfs.h>
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <getopt.h>
|
||||
#include <sys/prctl.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "alloc-util.h"
|
||||
|
||||
@@ -6,8 +6,6 @@
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <sys/file.h>
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/mount.h>
|
||||
|
||||
#include "sd-device.h"
|
||||
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
|
||||
#include <fcntl.h>
|
||||
#include <getopt.h>
|
||||
#include <linux/loop.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "sd-bus.h"
|
||||
@@ -51,7 +50,6 @@
|
||||
#include "terminal-util.h"
|
||||
#include "time-util.h"
|
||||
#include "tmpfile-util-label.h"
|
||||
#include "umask-util.h"
|
||||
#include "user-util.h"
|
||||
#include "vconsole-util.h"
|
||||
|
||||
|
||||
@@ -5,7 +5,6 @@
|
||||
|
||||
#include <fcntl.h>
|
||||
#include <sys/file.h>
|
||||
#include <sys/prctl.h>
|
||||
#include <sys/stat.h>
|
||||
#include <unistd.h>
|
||||
|
||||
|
||||
@@ -444,6 +444,7 @@ assert_cc(sizeof(dummy_t) == 0);
|
||||
#define DECLARE_SBAT(text)
|
||||
#endif
|
||||
|
||||
#define typeof_field(struct_type, member) typeof(((struct_type *) 0)->member)
|
||||
#define sizeof_field(struct_type, member) sizeof(((struct_type *) 0)->member)
|
||||
#define endoffsetof_field(struct_type, member) (offsetof(struct_type, member) + sizeof_field(struct_type, member))
|
||||
#define voffsetof(v, member) offsetof(typeof(v), member)
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <errno.h>
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "bus-label.h"
|
||||
#include "fuzz.h"
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "calendarspec.h"
|
||||
#include "fd-util.h"
|
||||
#include "fuzz.h"
|
||||
#include "string-util.h"
|
||||
#include "time-util.h"
|
||||
|
||||
@@ -1,9 +1,11 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <unistd.h>
|
||||
|
||||
#include "catalog.h"
|
||||
#include "fd-util.h"
|
||||
#include "fs-util.h"
|
||||
#include "fuzz.h"
|
||||
#include "hashmap.h"
|
||||
#include "tmpfile-util.h"
|
||||
|
||||
int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) {
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <errno.h>
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "compress.h"
|
||||
#include "fuzz.h"
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "env-file.h"
|
||||
#include "fd-util.h"
|
||||
#include "fuzz.h"
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
|
||||
#include "sd-json.h"
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "env-util.h"
|
||||
#include "fd-util.h"
|
||||
#include "fuzz.h"
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <stdlib.h>
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "fileio.h"
|
||||
#include "fuzz.h"
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "fd-util.h"
|
||||
#include "fuzz.h"
|
||||
#include "time-util.h"
|
||||
|
||||
|
||||
@@ -3,7 +3,6 @@
|
||||
#include "device-internal.h"
|
||||
#include "device-private.h"
|
||||
#include "fd-util.h"
|
||||
#include "fs-util.h"
|
||||
#include "fuzz.h"
|
||||
#include "tmpfile-util.h"
|
||||
|
||||
|
||||
@@ -1,16 +1,10 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <unistd.h>
|
||||
|
||||
#include "sd-varlink-idl.h"
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "errno-util.h"
|
||||
#include "fd-util.h"
|
||||
#include "fuzz.h"
|
||||
#include "io-util.h"
|
||||
#include "log.h"
|
||||
#include "string-util.h"
|
||||
#include "varlink-idl-util.h"
|
||||
|
||||
int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <unistd.h>
|
||||
#include <sys/socket.h>
|
||||
|
||||
#include "sd-varlink.h"
|
||||
|
||||
|
||||
+3
-4
@@ -1,11 +1,10 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
#pragma once
|
||||
|
||||
#include <stddef.h>
|
||||
#include <stdint.h>
|
||||
#include <stdio.h>
|
||||
|
||||
#include "forward.h"
|
||||
|
||||
#include "assert-util.h"
|
||||
#include "env-util.h"
|
||||
#include "fileio.h"
|
||||
#include "log.h"
|
||||
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <sys/file.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "sd-id128.h"
|
||||
|
||||
|
||||
@@ -2,9 +2,6 @@
|
||||
|
||||
#include <fcntl.h>
|
||||
#include <getopt.h>
|
||||
#include <linux/magic.h>
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/mount.h>
|
||||
#include <sys/vfs.h>
|
||||
|
||||
#include "alloc-util.h"
|
||||
|
||||
@@ -2,9 +2,7 @@
|
||||
|
||||
#include <fcntl.h>
|
||||
#include <sys/file.h>
|
||||
#include <sys/prctl.h>
|
||||
#include <sys/stat.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "blockdev-util.h"
|
||||
|
||||
@@ -14,6 +14,7 @@
|
||||
#include "bus-common-errors.h"
|
||||
#include "bus-get-properties.h"
|
||||
#include "bus-log-control-api.h"
|
||||
#include "bus-object.h"
|
||||
#include "bus-polkit.h"
|
||||
#include "bus-util.h"
|
||||
#include "constants.h"
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <sys/stat.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "fd-util.h"
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <getopt.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "ask-password-api.h"
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
#include "memory-util.h"
|
||||
#include "time-util.h"
|
||||
|
||||
typedef struct ICMP6Pakcet {
|
||||
typedef struct ICMP6Packet {
|
||||
unsigned n_ref;
|
||||
|
||||
struct in6_addr sender_address;
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <sys/stat.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "sd-bus.h"
|
||||
#include "sd-event.h"
|
||||
@@ -10,6 +9,7 @@
|
||||
#include "bus-error.h"
|
||||
#include "bus-locator.h"
|
||||
#include "bus-log-control-api.h"
|
||||
#include "bus-object.h"
|
||||
#include "bus-polkit.h"
|
||||
#include "bus-unit-util.h"
|
||||
#include "bus-util.h"
|
||||
@@ -23,7 +23,6 @@
|
||||
#include "service-util.h"
|
||||
#include "string-util.h"
|
||||
#include "strv.h"
|
||||
#include "time-util.h"
|
||||
|
||||
static int vconsole_reload(sd_bus *bus) {
|
||||
_cleanup_(sd_bus_error_free) sd_bus_error error = SD_BUS_ERROR_NULL;
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <sys/wait.h>
|
||||
|
||||
#include "sd-daemon.h"
|
||||
|
||||
|
||||
@@ -25,7 +25,6 @@
|
||||
#include "loop-util.h"
|
||||
#include "main-func.h"
|
||||
#include "memory-util.h"
|
||||
#include "missing_syscall.h"
|
||||
#include "namespace-util.h"
|
||||
#include "nsresource.h"
|
||||
#include "nulstr-util.h"
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <sys/mount.h>
|
||||
#include <sys/wait.h>
|
||||
|
||||
#include "sd-daemon.h"
|
||||
|
||||
|
||||
@@ -7,9 +7,8 @@
|
||||
#include <net/if.h>
|
||||
#include <poll.h>
|
||||
#include <sys/eventfd.h>
|
||||
#include <sys/mount.h>
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/wait.h>
|
||||
#include <utmpx.h>
|
||||
|
||||
#include "sd-daemon.h"
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <sys/stat.h>
|
||||
#include <sched.h>
|
||||
#include <sys/mount.h>
|
||||
|
||||
#include "bpf-dlopen.h"
|
||||
#include "bpf-link.h"
|
||||
#include "fd-util.h"
|
||||
#include "fs-util.h"
|
||||
#include "log.h"
|
||||
#include "lsm-util.h"
|
||||
#include "mkdir.h"
|
||||
|
||||
+2
-2
@@ -1,7 +1,8 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <getopt.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "sd-bus.h"
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "build.h"
|
||||
@@ -12,7 +13,6 @@
|
||||
#include "main-func.h"
|
||||
#include "pager.h"
|
||||
#include "pretty-print.h"
|
||||
#include "terminal-util.h"
|
||||
#include "verbs.h"
|
||||
|
||||
static PagerFlags arg_pager_flags = 0;
|
||||
|
||||
@@ -4,6 +4,9 @@
|
||||
#include "log.h"
|
||||
#include "oomd-conf.h"
|
||||
#include "oomd-manager.h"
|
||||
#include "parse-util.h"
|
||||
#include "string-util.h"
|
||||
#include "time-util.h"
|
||||
|
||||
static int config_parse_duration(
|
||||
const char *unit,
|
||||
|
||||
+1
-2
@@ -1,8 +1,7 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
#pragma once
|
||||
|
||||
#include "conf-parser.h"
|
||||
#include "oomd-manager.h"
|
||||
typedef struct Manager Manager;
|
||||
|
||||
void manager_set_defaults(Manager *m);
|
||||
|
||||
|
||||
@@ -1,15 +1,13 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <linux/capability.h>
|
||||
#include "sd-bus.h"
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "bus-common-errors.h"
|
||||
#include "bus-polkit.h"
|
||||
#include "bus-object.h"
|
||||
#include "fd-util.h"
|
||||
#include "memfd-util.h"
|
||||
#include "oomd-manager.h"
|
||||
#include "oomd-manager-bus.h"
|
||||
#include "user-util.h"
|
||||
|
||||
static int bus_method_dump_by_fd(sd_bus_message *message, void *userdata, sd_bus_error *error) {
|
||||
_cleanup_free_ char *dump = NULL;
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
#pragma once
|
||||
|
||||
#include "bus-object.h"
|
||||
|
||||
typedef struct Manager Manager;
|
||||
#include "forward.h"
|
||||
|
||||
extern const BusObjectImplementation manager_object;
|
||||
|
||||
@@ -1,25 +1,30 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include "sd-bus.h"
|
||||
#include "sd-daemon.h"
|
||||
#include "sd-event.h"
|
||||
#include "sd-json.h"
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "bus-log-control-api.h"
|
||||
#include "bus-polkit.h"
|
||||
#include "bus-object.h"
|
||||
#include "bus-util.h"
|
||||
#include "cgroup-util.h"
|
||||
#include "constants.h"
|
||||
#include "daemon-util.h"
|
||||
#include "fd-util.h"
|
||||
#include "fileio.h"
|
||||
#include "format-util.h"
|
||||
#include "json-util.h"
|
||||
#include "memory-util.h"
|
||||
#include "memstream-util.h"
|
||||
#include "oomd-conf.h"
|
||||
#include "oomd-manager.h"
|
||||
#include "oomd-manager-bus.h"
|
||||
#include "parse-util.h"
|
||||
#include "path-util.h"
|
||||
#include "percent-util.h"
|
||||
#include "set.h"
|
||||
#include "string-util.h"
|
||||
#include "time-util.h"
|
||||
#include "varlink-io.systemd.oom.h"
|
||||
#include "varlink-io.systemd.service.h"
|
||||
#include "varlink-util.h"
|
||||
|
||||
@@ -1,11 +1,8 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
#pragma once
|
||||
|
||||
#include "sd-bus.h"
|
||||
#include "sd-event.h"
|
||||
#include "sd-varlink.h"
|
||||
|
||||
#include "conf-parser.h"
|
||||
#include "conf-parser-forward.h"
|
||||
#include "forward.h"
|
||||
#include "oomd-util.h"
|
||||
|
||||
/* Polling interval for monitoring stats */
|
||||
@@ -27,9 +24,7 @@
|
||||
#define RECLAIM_DURATION_USEC (30 * USEC_PER_SEC)
|
||||
#define POST_ACTION_DELAY_USEC (15 * USEC_PER_SEC)
|
||||
|
||||
typedef struct Manager Manager;
|
||||
|
||||
struct Manager {
|
||||
typedef struct Manager {
|
||||
sd_bus *bus;
|
||||
sd_event *event;
|
||||
|
||||
@@ -59,7 +54,7 @@ struct Manager {
|
||||
/* This varlink server object is used to manage systemd-oomd's varlink server which is used by user
|
||||
* managers to report changes in ManagedOOM settings (oomd server - systemd client). */
|
||||
sd_varlink_server *varlink_server;
|
||||
};
|
||||
} Manager;
|
||||
|
||||
Manager* manager_free(Manager *m);
|
||||
DEFINE_TRIVIAL_CLEANUP_FUNC(Manager*, manager_free);
|
||||
|
||||
+5
-5
@@ -1,8 +1,6 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <sys/xattr.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "errno-util.h"
|
||||
#include "fd-util.h"
|
||||
#include "fileio.h"
|
||||
@@ -12,12 +10,14 @@
|
||||
#include "oomd-util.h"
|
||||
#include "parse-util.h"
|
||||
#include "path-util.h"
|
||||
#include "pidref.h"
|
||||
#include "procfs-util.h"
|
||||
#include "set.h"
|
||||
#include "signal-util.h"
|
||||
#include "sort-util.h"
|
||||
#include "stat-util.h"
|
||||
#include "stdio-util.h"
|
||||
#include "user-util.h"
|
||||
#include "string-util.h"
|
||||
#include "time-util.h"
|
||||
|
||||
DEFINE_HASH_OPS_WITH_VALUE_DESTRUCTOR(
|
||||
oomd_cgroup_ctx_hash_ops,
|
||||
|
||||
+1
-3
@@ -1,10 +1,8 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
#pragma once
|
||||
|
||||
#include <stdbool.h>
|
||||
|
||||
#include "cgroup-util.h"
|
||||
#include "hashmap.h"
|
||||
#include "forward.h"
|
||||
#include "psi-util.h"
|
||||
|
||||
#define DUMP_ON_KILL_COUNT 10u
|
||||
|
||||
+2
-2
@@ -2,12 +2,13 @@
|
||||
|
||||
#include <getopt.h>
|
||||
|
||||
#include "sd-event.h"
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "build.h"
|
||||
#include "bus-log-control-api.h"
|
||||
#include "bus-object.h"
|
||||
#include "cgroup-util.h"
|
||||
#include "conf-parser.h"
|
||||
#include "daemon-util.h"
|
||||
#include "fileio.h"
|
||||
#include "log.h"
|
||||
@@ -18,7 +19,6 @@
|
||||
#include "parse-util.h"
|
||||
#include "pretty-print.h"
|
||||
#include "psi-util.h"
|
||||
#include "signal-util.h"
|
||||
|
||||
static bool arg_dry_run = false;
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "alloc-util.h"
|
||||
@@ -7,13 +8,12 @@
|
||||
#include "cgroup-util.h"
|
||||
#include "fd-util.h"
|
||||
#include "fileio.h"
|
||||
#include "fs-util.h"
|
||||
#include "oomd-util.h"
|
||||
#include "parse-util.h"
|
||||
#include "path-util.h"
|
||||
#include "string-util.h"
|
||||
#include "strv.h"
|
||||
#include "set.h"
|
||||
#include "tests.h"
|
||||
#include "time-util.h"
|
||||
#include "tmpfile-util.h"
|
||||
|
||||
static int fork_and_sleep(unsigned sleep_min) {
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <fcntl.h>
|
||||
#include <sys/stat.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "sd-bus.h"
|
||||
|
||||
@@ -3,7 +3,6 @@
|
||||
|
||||
#include "sd-bus-vtable.h"
|
||||
|
||||
#include "bus-object.h"
|
||||
#include "portabled-forward.h"
|
||||
|
||||
int bus_image_common_get_os_release(Manager *m, sd_bus_message *message, const char *name_or_path, Image *image, sd_bus_error *error);
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "bus-log-control-api.h"
|
||||
#include "bus-object.h"
|
||||
#include "bus-util.h"
|
||||
#include "common-signal.h"
|
||||
#include "constants.h"
|
||||
@@ -15,10 +16,8 @@
|
||||
#include "log.h"
|
||||
#include "main-func.h"
|
||||
#include "portabled.h"
|
||||
#include "portabled-image-bus.h"
|
||||
#include "service-util.h"
|
||||
#include "signal-util.h"
|
||||
#include "time-util.h"
|
||||
|
||||
static Manager* manager_unref(Manager *m);
|
||||
DEFINE_TRIVIAL_CLEANUP_FUNC(Manager*, manager_unref);
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
#pragma once
|
||||
|
||||
#include "bus-object.h"
|
||||
#include "list.h"
|
||||
#include "portabled-forward.h"
|
||||
#include "runtime-scope.h"
|
||||
|
||||
@@ -5,9 +5,6 @@
|
||||
/* Generally speaking, the pstore contains a small number of files
|
||||
* that in turn contain a small amount of data. */
|
||||
#include <stdio.h>
|
||||
#include <stdio_ext.h>
|
||||
#include <sys/prctl.h>
|
||||
#include <sys/xattr.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "sd-journal.h"
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <sys/prctl.h>
|
||||
#include <sys/stat.h>
|
||||
#include <unistd.h>
|
||||
|
||||
|
||||
@@ -2,9 +2,7 @@
|
||||
|
||||
#include <fcntl.h>
|
||||
#include <getopt.h>
|
||||
#include <linux/random.h>
|
||||
#include <stdlib.h>
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/xattr.h>
|
||||
#include <unistd.h>
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <mntent.h>
|
||||
#include <sys/prctl.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/wait.h>
|
||||
#include <unistd.h>
|
||||
|
||||
@@ -1,12 +1,7 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#if HAVE_VALGRIND_MEMCHECK_H
|
||||
#include <valgrind/memcheck.h>
|
||||
#endif
|
||||
|
||||
#include <fcntl.h>
|
||||
#include <getopt.h>
|
||||
#include <linux/loop.h>
|
||||
#include <sys/file.h>
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <sys/un.h>
|
||||
|
||||
#include "fd-util.h"
|
||||
#include "fileio.h"
|
||||
#include "log.h"
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include "conf-files.h"
|
||||
#include "constants.h"
|
||||
#include "dns-domain.h"
|
||||
#include "in-addr-util.h"
|
||||
#include "path-util.h"
|
||||
|
||||
@@ -5,7 +5,6 @@
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <sys/resource.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
#include "sd-bus.h"
|
||||
#include "sd-daemon.h"
|
||||
|
||||
@@ -0,0 +1,44 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
#pragma once
|
||||
|
||||
#include "cleanup-util.h"
|
||||
|
||||
/* Argument list for parsers of specific configuration settings. */
|
||||
#define CONFIG_PARSER_ARGUMENTS \
|
||||
const char *unit, \
|
||||
const char *filename, \
|
||||
unsigned line, \
|
||||
const char *section, \
|
||||
unsigned section_line, \
|
||||
const char *lvalue, \
|
||||
int ltype, \
|
||||
const char *rvalue, \
|
||||
void *data, \
|
||||
void *userdata
|
||||
|
||||
/* Prototype for a parser for a specific configuration setting */
|
||||
typedef int (*ConfigParserCallback)(CONFIG_PARSER_ARGUMENTS);
|
||||
|
||||
/* A macro declaring a function prototype, following the typedef above, simply because it's so cumbersomely long
|
||||
* otherwise. (And current emacs gets irritatingly slow when editing files that contain lots of very long function
|
||||
* prototypes on the same screen…) */
|
||||
#define CONFIG_PARSER_PROTOTYPE(name) int name(CONFIG_PARSER_ARGUMENTS)
|
||||
|
||||
typedef struct ConfigSection {
|
||||
unsigned line;
|
||||
bool invalid;
|
||||
char filename[];
|
||||
} ConfigSection;
|
||||
|
||||
#define DEFINE_SECTION_CLEANUP_FUNCTIONS(type, free_func) \
|
||||
static inline type* free_func##_or_set_invalid(type *p) { \
|
||||
assert(p); \
|
||||
\
|
||||
if (p->section) \
|
||||
p->section->invalid = true; \
|
||||
else \
|
||||
free_func(p); \
|
||||
return NULL; \
|
||||
} \
|
||||
DEFINE_TRIVIAL_CLEANUP_FUNC(type*, free_func); \
|
||||
DEFINE_TRIVIAL_CLEANUP_FUNC(type*, free_func##_or_set_invalid);
|
||||
@@ -8,6 +8,7 @@
|
||||
#include <sys/stat.h>
|
||||
#include <syslog.h>
|
||||
|
||||
#include "conf-parser-forward.h"
|
||||
#include "hashmap.h"
|
||||
#include "log.h"
|
||||
#include "memory-util.h"
|
||||
@@ -19,27 +20,6 @@ typedef enum ConfigParseFlags {
|
||||
CONFIG_PARSE_WARN = 1 << 1, /* Emit non-debug messages */
|
||||
} ConfigParseFlags;
|
||||
|
||||
/* Argument list for parsers of specific configuration settings. */
|
||||
#define CONFIG_PARSER_ARGUMENTS \
|
||||
const char *unit, \
|
||||
const char *filename, \
|
||||
unsigned line, \
|
||||
const char *section, \
|
||||
unsigned section_line, \
|
||||
const char *lvalue, \
|
||||
int ltype, \
|
||||
const char *rvalue, \
|
||||
void *data, \
|
||||
void *userdata
|
||||
|
||||
/* Prototype for a parser for a specific configuration setting */
|
||||
typedef int (*ConfigParserCallback)(CONFIG_PARSER_ARGUMENTS);
|
||||
|
||||
/* A macro declaring a function prototype, following the typedef above, simply because it's so cumbersomely long
|
||||
* otherwise. (And current emacs gets irritatingly slow when editing files that contain lots of very long function
|
||||
* prototypes on the same screen…) */
|
||||
#define CONFIG_PARSER_PROTOTYPE(name) int name(CONFIG_PARSER_ARGUMENTS)
|
||||
|
||||
/* Wraps information for parsing a specific configuration variable, to
|
||||
* be stored in a simple array */
|
||||
typedef struct ConfigTableItem {
|
||||
@@ -164,12 +144,6 @@ int config_section_parse(
|
||||
const char *rvalue,
|
||||
void *userdata);
|
||||
|
||||
typedef struct ConfigSection {
|
||||
unsigned line;
|
||||
bool invalid;
|
||||
char filename[];
|
||||
} ConfigSection;
|
||||
|
||||
static inline ConfigSection* config_section_free(ConfigSection *cs) {
|
||||
return mfree(cs);
|
||||
}
|
||||
@@ -207,19 +181,6 @@ static inline bool section_is_invalid(ConfigSection *section) {
|
||||
return section->invalid;
|
||||
}
|
||||
|
||||
#define DEFINE_SECTION_CLEANUP_FUNCTIONS(type, free_func) \
|
||||
static inline type* free_func##_or_set_invalid(type *p) { \
|
||||
assert(p); \
|
||||
\
|
||||
if (p->section) \
|
||||
p->section->invalid = true; \
|
||||
else \
|
||||
free_func(p); \
|
||||
return NULL; \
|
||||
} \
|
||||
DEFINE_TRIVIAL_CLEANUP_FUNC(type*, free_func); \
|
||||
DEFINE_TRIVIAL_CLEANUP_FUNC(type*, free_func##_or_set_invalid);
|
||||
|
||||
#define log_section_full_errno_zerook(section, level, error, ...) \
|
||||
({ \
|
||||
const ConfigSection *_s = (section); \
|
||||
|
||||
@@ -29,7 +29,7 @@ typedef struct {} pcre2_code;
|
||||
|
||||
extern const struct hash_ops pcre2_code_hash_ops_free;
|
||||
|
||||
typedef enum {
|
||||
typedef enum PatternCompileCase {
|
||||
PATTERN_COMPILE_CASE_AUTO,
|
||||
PATTERN_COMPILE_CASE_SENSITIVE,
|
||||
PATTERN_COMPILE_CASE_INSENSITIVE,
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
#include "argv-util.h"
|
||||
#include "errno-util.h"
|
||||
#include "extract-word.h"
|
||||
#include "forward.h"
|
||||
#include "log.h"
|
||||
#include "macro.h"
|
||||
#include "process-util.h"
|
||||
|
||||
@@ -5,7 +5,6 @@
|
||||
|
||||
#include <linux/loop.h>
|
||||
#include <sys/ioctl.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#if HAVE_VALGRIND_MEMCHECK_H
|
||||
#include <valgrind/memcheck.h>
|
||||
|
||||
@@ -6,7 +6,6 @@
|
||||
#include <linux/major.h>
|
||||
#include <linux/raid/md_u.h>
|
||||
#include <sys/ioctl.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "sd-device.h"
|
||||
|
||||
|
||||
@@ -5,11 +5,11 @@
|
||||
|
||||
#include <fcntl.h>
|
||||
#include <sys/mount.h>
|
||||
#include <sys/stat.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "chase.h"
|
||||
#include "constants.h"
|
||||
#include "dirent-util.h"
|
||||
#include "errno-util.h"
|
||||
#include "fd-util.h"
|
||||
@@ -29,7 +29,6 @@
|
||||
#include "signal-util.h"
|
||||
#include "stat-util.h"
|
||||
#include "string-util.h"
|
||||
#include "time-util.h"
|
||||
#include "umount.h"
|
||||
#include "virt.h"
|
||||
|
||||
|
||||
@@ -13,6 +13,7 @@
|
||||
#include "parse-util.h"
|
||||
#include "siphash24.h"
|
||||
#include "string-util.h"
|
||||
#include "time-util.h"
|
||||
|
||||
#define DISCHARGE_RATE_FILEPATH "/var/lib/systemd/sleep/battery_discharge_percentage_rate_per_hour"
|
||||
#define BATTERY_DISCHARGE_RATE_HASH_KEY SD_ID128_MAKE(5f,9a,20,18,38,76,46,07,8d,36,58,0b,bb,c4,e0,63)
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
#pragma once
|
||||
|
||||
#include "hashmap.h"
|
||||
#include "time-util.h"
|
||||
|
||||
int fetch_batteries_capacity_by_name(Hashmap **ret_current_capacity);
|
||||
int get_capacity_by_name(Hashmap *capacities_by_name, const char *name);
|
||||
|
||||
@@ -10,7 +10,6 @@
|
||||
#include <stdlib.h>
|
||||
#include <sys/timerfd.h>
|
||||
#include <sys/utsname.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "sd-bus.h"
|
||||
#include "sd-device.h"
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
#include "hashmap.h"
|
||||
#include "log.h"
|
||||
#include "tests.h"
|
||||
#include "time-util.h"
|
||||
|
||||
TEST(fetch_batteries_capacity_by_name) {
|
||||
_cleanup_hashmap_free_ Hashmap *capacity = NULL;
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
|
||||
#include <getopt.h>
|
||||
#include <sys/epoll.h>
|
||||
#include <sys/prctl.h>
|
||||
#include <sys/wait.h>
|
||||
#include <unistd.h>
|
||||
|
||||
|
||||
@@ -4,7 +4,6 @@
|
||||
#include <getopt.h>
|
||||
#include <netdb.h>
|
||||
#include <stdio.h>
|
||||
#include <sys/un.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "sd-daemon.h"
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <fcntl.h>
|
||||
#include <sys/ioctl.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "alloc-util.h"
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <net/if_arp.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "sd-varlink.h"
|
||||
|
||||
@@ -3,8 +3,6 @@
|
||||
Copyright © 2017 Felipe Sateler
|
||||
***/
|
||||
|
||||
#include <sys/prctl.h>
|
||||
|
||||
#include "sd-bus.h"
|
||||
|
||||
#include "alloc-util.h"
|
||||
|
||||
@@ -35,7 +35,6 @@
|
||||
#include "log.h"
|
||||
#include "loop-util.h"
|
||||
#include "main-func.h"
|
||||
#include "missing_magic.h"
|
||||
#include "mkdir.h"
|
||||
#include "mount-util.h"
|
||||
#include "mountpoint-util.h"
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
|
||||
#include "bus-error.h"
|
||||
#include "bus-locator.h"
|
||||
#include "constants.h"
|
||||
#include "systemctl.h"
|
||||
#include "systemctl-daemon-reload.h"
|
||||
#include "systemctl-util.h"
|
||||
|
||||
@@ -4,7 +4,6 @@
|
||||
#include <stdio.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "log.h"
|
||||
#include "nss-test-util.h"
|
||||
#include "string-util.h"
|
||||
|
||||
@@ -2,7 +2,8 @@
|
||||
#pragma once
|
||||
|
||||
#include <nss.h>
|
||||
#include <stdint.h>
|
||||
|
||||
#include "forward.h"
|
||||
|
||||
const char* nss_status_to_string(enum nss_status status, char *buf, size_t buf_len);
|
||||
void* nss_open_handle(const char *dir, const char *module, int flags);
|
||||
|
||||
@@ -9,9 +9,9 @@
|
||||
#include "errno-util.h"
|
||||
#include "fd-util.h"
|
||||
#include "format-util.h"
|
||||
#include "fs-util.h"
|
||||
#include "path-util.h"
|
||||
#include "string-util.h"
|
||||
#include "strv.h"
|
||||
#include "tests.h"
|
||||
#include "tmpfile-util.h"
|
||||
#include "user-util.h"
|
||||
|
||||
@@ -1,9 +1,5 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <sys/socket.h>
|
||||
|
||||
#include "macro.h"
|
||||
#include "string-util.h"
|
||||
#include "tests.h"
|
||||
|
||||
_unused_
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <malloc.h>
|
||||
#include <stdint.h>
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "macro.h"
|
||||
#include "memory-util.h"
|
||||
#include "random-util.h"
|
||||
#include "tests.h"
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <linux/if_arp.h>
|
||||
#include <net/if.h>
|
||||
|
||||
#include "arphrd-util.h"
|
||||
#include "string-util.h"
|
||||
#include "tests.h"
|
||||
|
||||
TEST(arphrd) {
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <fcntl.h>
|
||||
#include <sys/prctl.h>
|
||||
#include <sys/wait.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "async.h"
|
||||
#include "fs-util.h"
|
||||
#include "path-util.h"
|
||||
#include "pidref.h"
|
||||
#include "process-util.h"
|
||||
#include "signal-util.h"
|
||||
#include "tests.h"
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include "audit-util.h"
|
||||
#include "format-util.h"
|
||||
#include "pidref.h"
|
||||
#include "tests.h"
|
||||
|
||||
TEST(audit_loginuid_from_pid) {
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
* increase it at the slightly cost of lengthen test-duration on other machines.
|
||||
*/
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <sys/time.h>
|
||||
#include <sys/wait.h>
|
||||
#include <unistd.h>
|
||||
|
||||
@@ -1,9 +1,6 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <stddef.h>
|
||||
|
||||
#include "bitfield.h"
|
||||
#include "log.h"
|
||||
#include "tests.h"
|
||||
|
||||
#define TEST_BITS(bits, v, ...) \
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include "sd-daemon.h"
|
||||
|
||||
#include "blockdev-util.h"
|
||||
#include "device-util.h"
|
||||
#include "errno-util.h"
|
||||
|
||||
@@ -1,14 +1,12 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "acpi-fpdt.h"
|
||||
#include "boot-timestamps.h"
|
||||
#include "efi-loader.h"
|
||||
#include "errno-util.h"
|
||||
#include "log.h"
|
||||
#include "tests.h"
|
||||
#include "time-util.h"
|
||||
|
||||
static int test_acpi_fpdt(void) {
|
||||
usec_t loader_start, loader_exit;
|
||||
|
||||
@@ -1,17 +1,17 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <sys/resource.h>
|
||||
#include <sys/time.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "bpf-devices.h"
|
||||
#include "bpf-program.h"
|
||||
#include "cgroup-setup.h"
|
||||
#include "cgroup.h"
|
||||
#include "errno-list.h"
|
||||
#include "fd-util.h"
|
||||
#include "fs-util.h"
|
||||
#include "path-util.h"
|
||||
#include "strv.h"
|
||||
#include "tests.h"
|
||||
|
||||
static void test_policy_closed(const char *cgroup_path, BPFProgram **installed_prog) {
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <linux/bpf_insn.h>
|
||||
#include <string.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "bpf-firewall.h"
|
||||
@@ -10,8 +9,10 @@
|
||||
#include "load-fragment.h"
|
||||
#include "manager.h"
|
||||
#include "memory-util.h"
|
||||
#include "path-util.h"
|
||||
#include "rm-rf.h"
|
||||
#include "service.h"
|
||||
#include "set.h"
|
||||
#include "tests.h"
|
||||
#include "unit-serialize.h"
|
||||
#include "virt.h"
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <fcntl.h>
|
||||
#include <linux/bpf.h>
|
||||
#include <linux/bpf_insn.h>
|
||||
#include <string.h>
|
||||
#include <sys/mman.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "bpf-foreign.h"
|
||||
#include "bpf-program.h"
|
||||
#include "load-fragment.h"
|
||||
#include "manager.h"
|
||||
#include "process-util.h"
|
||||
#include "rlimit-util.h"
|
||||
#include "rm-rf.h"
|
||||
#include "service.h"
|
||||
#include "strv.h"
|
||||
#include "tests.h"
|
||||
#include "unit.h"
|
||||
#include "virt.h"
|
||||
|
||||
@@ -10,7 +10,6 @@
|
||||
#include "strv.h"
|
||||
#include "tests.h"
|
||||
#include "unit.h"
|
||||
#include "virt.h"
|
||||
|
||||
static int test_restrict_filesystems(Manager *m, const char *unit_name, const char *file_path, char **allowed_filesystems) {
|
||||
_cleanup_free_ char *exec_start = NULL;
|
||||
|
||||
@@ -1,11 +1,9 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <errno.h>
|
||||
#include <fcntl.h>
|
||||
|
||||
#include "btrfs-util.h"
|
||||
#include "fd-util.h"
|
||||
#include "format-util.h"
|
||||
#include "log.h"
|
||||
#include "memory-util.h"
|
||||
#include "tests.h"
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
|
||||
#include <fcntl.h>
|
||||
#include <sys/file.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
#include "btrfs-util.h"
|
||||
#include "fd-util.h"
|
||||
@@ -11,6 +12,7 @@
|
||||
#include "log.h"
|
||||
#include "string-util.h"
|
||||
#include "tests.h"
|
||||
#include "time-util.h"
|
||||
|
||||
int main(int argc, char *argv[]) {
|
||||
BtrfsQuotaInfo quota;
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include "sd-bus.h"
|
||||
|
||||
#include "bus-util.h"
|
||||
#include "log.h"
|
||||
#include "tests.h"
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user