diff options
author | Luke Shumaker <lukeshu@sbcglobal.net> | 2016-09-11 22:56:30 -0400 |
---|---|---|
committer | Luke Shumaker <lukeshu@sbcglobal.net> | 2016-09-11 22:56:30 -0400 |
commit | fa89550518af96a8804749c0ab0916599a94c1da (patch) | |
tree | 57db50190ad4bcdbc9ef54efc528db4286daedac /src/systemd-nspawn | |
parent | f4b50a2aa19f5a99008565f4127952ea8f2e4f61 (diff) |
Run the new fixup script.
The biggest change is that it keeps looking for new #include
blocks. This means that it (more) correctly handles #ifdef'd
#includes.
I'm not 100% in love with it, but it's pretty good for automated.
What I really don't like is it did some silly things with newlines
in typedef blocks. I've avoided committing those. I think it may
be possible to get it to do the right thing. But really, the
typedef blocks are a hack for poorly structured headers.
Now that it keeps looking for new #include blocks, I could strip
out the typedef support, and it would mostly work; but it wouldn't
be able to move some headers back to the top.
IDK what to do.
Diffstat (limited to 'src/systemd-nspawn')
-rw-r--r-- | src/systemd-nspawn/nspawn-patch-uid.c | 5 | ||||
-rw-r--r-- | src/systemd-nspawn/nspawn.c | 30 |
2 files changed, 19 insertions, 16 deletions
diff --git a/src/systemd-nspawn/nspawn-patch-uid.c b/src/systemd-nspawn/nspawn-patch-uid.c index 2cdb541ebb..28d2801c69 100644 --- a/src/systemd-nspawn/nspawn-patch-uid.c +++ b/src/systemd-nspawn/nspawn-patch-uid.c @@ -27,16 +27,17 @@ #include <sys/vfs.h> #include <unistd.h> -#include "shared/acl-util.h" #include "basic/dirent-util.h" #include "basic/fd-util.h" #include "basic/missing.h" -#include "nspawn-patch-uid.h" #include "basic/stat-util.h" #include "basic/stdio-util.h" #include "basic/string-util.h" #include "basic/strv.h" #include "basic/user-util.h" +#include "shared/acl-util.h" + +#include "nspawn-patch-uid.h" #ifdef HAVE_ACL diff --git a/src/systemd-nspawn/nspawn.c b/src/systemd-nspawn/nspawn.c index fc913a2363..5537a526f0 100644 --- a/src/systemd-nspawn/nspawn.c +++ b/src/systemd-nspawn/nspawn.c @@ -23,9 +23,10 @@ #include <errno.h> #include <getopt.h> #include <grp.h> -#include <linux/loop.h> #include <pwd.h> #include <sched.h> + +#include <linux/loop.h> #ifdef HAVE_SECCOMP #include <seccomp.h> #endif @@ -48,30 +49,37 @@ #include "basic/alloc-util.h" #include "basic/barrier.h" -#include "shared/base-filesystem.h" #include "basic/blkid-util.h" #include "basic/btrfs-util.h" #include "basic/cap-list.h" #include "basic/capability-util.h" #include "basic/cgroup-util.h" #include "basic/copy.h" -#include "shared/dev-setup.h" #include "basic/env-util.h" #include "basic/fd-util.h" #include "basic/fdset.h" #include "basic/fileio.h" #include "basic/formats-util.h" #include "basic/fs-util.h" -#include "shared/gpt.h" #include "basic/hostname-util.h" #include "basic/log.h" -#include "loopback-setup.h" -#include "machine-id-setup.h" -#include "shared/machine-image.h" #include "basic/macro.h" #include "basic/missing.h" #include "basic/mkdir.h" #include "basic/mount-util.h" +#include "basic/parse-util.h" +#include "basic/path-util.h" +#include "basic/process-util.h" +#include "basic/random-util.h" +#include "basic/rm-rf.h" +#include "shared/base-filesystem.h" +#include "shared/dev-setup.h" +#include "shared/gpt.h" +#include "shared/machine-image.h" +#include "shared/ptyfwd.h" + +#include "loopback-setup.h" +#include "machine-id-setup.h" #include "nspawn-cgroup.h" #include "nspawn-expose-ports.h" #include "nspawn-mount.h" @@ -81,12 +89,6 @@ #include "nspawn-settings.h" #include "nspawn-setuid.h" #include "nspawn-stub-pid1.h" -#include "basic/parse-util.h" -#include "basic/path-util.h" -#include "basic/process-util.h" -#include "shared/ptyfwd.h" -#include "basic/random-util.h" -#include "basic/rm-rf.h" #ifdef HAVE_SECCOMP #include "shared/seccomp-util.h" #endif @@ -98,10 +100,10 @@ #include "basic/string-util.h" #include "basic/strv.h" #include "basic/terminal-util.h" -#include "shared/udev-util.h" #include "basic/umask-util.h" #include "basic/user-util.h" #include "basic/util.h" +#include "shared/udev-util.h" /* Note that devpts's gid= parameter parses GIDs as signed values, hence we stay away from the upper half of the 32bit * UID range here */ |