From 66e0bb76b40311245b9c59e2f3167e4e98027eba Mon Sep 17 00:00:00 2001 From: David Robillard Date: Tue, 16 Aug 2022 16:38:19 -0400 Subject: Fix whitespace Apparently clang-format changed its mind about special member functions, and binary_location.h was just never formatted to begin with. --- src/binary_location.h | 38 +++++++++++++++++++------------------- 1 file changed, 19 insertions(+), 19 deletions(-) (limited to 'src/binary_location.h') diff --git a/src/binary_location.h b/src/binary_location.h index 0cc3688..12f726e 100644 --- a/src/binary_location.h +++ b/src/binary_location.h @@ -13,31 +13,31 @@ namespace patchage { inline std::string binary_location() { - Dl_info dli = {}; - const int ret = dladdr(reinterpret_cast(&binary_location), &dli); - if (!ret) { - return ""; - } - - char* const bin_loc = realpath(dli.dli_fname, nullptr); - if (!bin_loc) { - return ""; - } - - std::string loc{bin_loc}; - free(bin_loc); - return loc; + Dl_info dli = {}; + const int ret = dladdr(reinterpret_cast(&binary_location), &dli); + if (!ret) { + return ""; + } + + char* const bin_loc = realpath(dli.dli_fname, nullptr); + if (!bin_loc) { + return ""; + } + + std::string loc{bin_loc}; + free(bin_loc); + return loc; } /** Return the absolute path of the bundle (binary parent directory). */ inline std::string bundle_location() { - const std::string binary = binary_location(); - if (binary.empty()) { - return ""; - } - return binary.substr(0, binary.find_last_of('/')); + const std::string binary = binary_location(); + if (binary.empty()) { + return ""; + } + return binary.substr(0, binary.find_last_of('/')); } } // namespace patchage -- cgit v1.2.1