From 037c8d771d56095617b4c2cbfd07ef1199905685 Mon Sep 17 00:00:00 2001 From: John Ericson Date: Thu, 2 May 2024 21:41:24 -0400 Subject: [PATCH] Fix format errors Fix formatting violations, update blacklist to reflect moved files. PR #10556 passed CI before the new formating rules were added, and our CI has the race condition of allowing old results, resulting in master getting broken. --- maintainers/flake-module.nix | 6 +++--- src/libstore/indirect-root-store.cc | 6 +++--- src/libutil/unix-domain-socket.hh | 6 ++---- 3 files changed, 8 insertions(+), 10 deletions(-) diff --git a/maintainers/flake-module.nix b/maintainers/flake-module.nix index 2ea94e9d9..d35b03148 100644 --- a/maintainers/flake-module.nix +++ b/maintainers/flake-module.nix @@ -252,8 +252,8 @@ ''^src/libstore/unix/pathlocks\.cc$'' ''^src/libstore/unix/posix-fs-canonicalise\.cc$'' ''^src/libstore/unix/posix-fs-canonicalise\.hh$'' - ''^src/libstore/unix/uds-remote-store\.cc$'' - ''^src/libstore/unix/uds-remote-store\.hh$'' + ''^src/libstore/uds-remote-store\.cc$'' + ''^src/libstore/uds-remote-store\.hh$'' ''^src/libstore/windows/build\.cc$'' ''^src/libstore/worker-protocol-impl\.hh$'' ''^src/libstore/worker-protocol\.cc$'' @@ -350,7 +350,7 @@ ''^src/libutil/unix/processes\.cc$'' ''^src/libutil/unix/signals-impl\.hh$'' ''^src/libutil/unix/signals\.cc$'' - ''^src/libutil/unix/unix-domain-socket\.cc$'' + ''^src/libutil/unix-domain-socket\.cc$'' ''^src/libutil/unix/users\.cc$'' ''^src/libutil/url-parts\.hh$'' ''^src/libutil/url\.cc$'' diff --git a/src/libstore/indirect-root-store.cc b/src/libstore/indirect-root-store.cc index b92279928..9da05778d 100644 --- a/src/libstore/indirect-root-store.cc +++ b/src/libstore/indirect-root-store.cc @@ -15,15 +15,15 @@ void IndirectRootStore::makeSymlink(const Path & link, const Path & target) renameFile(tempLink, link); } - Path IndirectRootStore::addPermRoot(const StorePath & storePath, const Path & _gcRoot) { Path gcRoot(canonPath(_gcRoot)); if (isInStore(gcRoot)) throw Error( - "creating a garbage collector root (%1%) in the Nix store is forbidden " - "(are you running nix-build inside the store?)", gcRoot); + "creating a garbage collector root (%1%) in the Nix store is forbidden " + "(are you running nix-build inside the store?)", + gcRoot); /* Register this root with the garbage collector, if it's running. This should be superfluous since the caller should diff --git a/src/libutil/unix-domain-socket.hh b/src/libutil/unix-domain-socket.hh index 9aba9f628..a8bbc4b89 100644 --- a/src/libutil/unix-domain-socket.hh +++ b/src/libutil/unix-domain-socket.hh @@ -5,7 +5,7 @@ #include "file-descriptor.hh" #ifdef _WIN32 -# include +# include #endif #include @@ -21,7 +21,6 @@ AutoCloseFD createUnixDomainSocket(); */ AutoCloseFD createUnixDomainSocket(const Path & path, mode_t mode); - /** * Often we want to use `Descriptor`, but Windows makes a slightly * stronger file descriptor vs socket distinction, at least at the level @@ -39,7 +38,7 @@ using Socket = /** * Windows gives this a different name */ -# define SHUT_WR SD_SEND +# define SHUT_WR SD_SEND #endif /** @@ -70,7 +69,6 @@ static inline Descriptor fromSocket(Socket fd) #endif } - /** * Bind a Unix domain socket to a path. */