From b4c5b1f942cfe11d19b5cca386834d4681e6b5e1 Mon Sep 17 00:00:00 2001 From: Shawn Zhong Date: Tue, 12 Oct 2021 19:54:40 -0500 Subject: [PATCH] Update .clang-format --- .clang-format | 67 +-------------------------------------------------- src/lib.cpp | 9 ++++--- 2 files changed, 6 insertions(+), 70 deletions(-) diff --git a/.clang-format b/.clang-format index 9dbcab56..2593ef54 100644 --- a/.clang-format +++ b/.clang-format @@ -1,66 +1 @@ -# Generated from CLion C/C++ Code Style settings -BasedOnStyle: LLVM -AccessModifierOffset: -3 -AlignAfterOpenBracket: Align -AlignConsecutiveAssignments: None -AlignOperands: DontAlign -AllowAllArgumentsOnNextLine: false -AllowAllConstructorInitializersOnNextLine: false -AllowAllParametersOfDeclarationOnNextLine: false -AllowShortBlocksOnASingleLine: Always -AllowShortCaseLabelsOnASingleLine: true -AllowShortFunctionsOnASingleLine: All -AllowShortIfStatementsOnASingleLine: Always -AllowShortLambdasOnASingleLine: All -AllowShortLoopsOnASingleLine: true -AlwaysBreakAfterReturnType: None -AlwaysBreakTemplateDeclarations: Yes -BreakBeforeBraces: Custom -BraceWrapping: - AfterCaseLabel: false - AfterClass: false - AfterControlStatement: Never - AfterEnum: false - AfterFunction: false - AfterNamespace: false - AfterUnion: false - BeforeCatch: false - BeforeElse: false - IndentBraces: false - SplitEmptyFunction: false - SplitEmptyRecord: true -BreakBeforeBinaryOperators: NonAssignment -BreakBeforeTernaryOperators: true -BreakConstructorInitializers: BeforeColon -BreakInheritanceList: BeforeColon -ColumnLimit: 0 -CompactNamespaces: false -ContinuationIndentWidth: 4 -IndentCaseLabels: true -IndentPPDirectives: None -IndentWidth: 4 -KeepEmptyLinesAtTheStartOfBlocks: true -MaxEmptyLinesToKeep: 1 -NamespaceIndentation: None -ObjCSpaceAfterProperty: false -ObjCSpaceBeforeProtocolList: false -PointerAlignment: Right -ReflowComments: false -SpaceAfterCStyleCast: true -SpaceAfterLogicalNot: false -SpaceAfterTemplateKeyword: false -SpaceBeforeAssignmentOperators: true -SpaceBeforeCpp11BracedList: false -SpaceBeforeCtorInitializerColon: true -SpaceBeforeInheritanceColon: true -SpaceBeforeParens: ControlStatements -SpaceBeforeRangeBasedForLoopColon: true -SpaceInEmptyParentheses: false -SpacesBeforeTrailingComments: 0 -SpacesInAngles: false -SpacesInCStyleCastParentheses: false -SpacesInContainerLiterals: false -SpacesInParentheses: false -SpacesInSquareBrackets: false -TabWidth: 4 -UseTab: Never +BasedOnStyle: Google \ No newline at end of file diff --git a/src/lib.cpp b/src/lib.cpp index 8b1c75e8..caf7597d 100644 --- a/src/lib.cpp +++ b/src/lib.cpp @@ -1,15 +1,16 @@ -#include #include #include +#include + namespace ulayfs { namespace posix { -#define REGISTER_FN(name) \ +#define REGISTER_FN(name) \ auto name = reinterpret_cast(dlsym(RTLD_NEXT, #name)) REGISTER_FN(write); REGISTER_FN(read); -} // namespace posix +} // namespace posix extern "C" { ssize_t write(int fd, const void *buf, size_t count) { @@ -22,4 +23,4 @@ ssize_t read(int fd, void *buf, size_t count) { return posix::write(fd, buf, count); } } -} // namespace ulayfs \ No newline at end of file +} // namespace ulayfs \ No newline at end of file