diff options
Diffstat (limited to 'zen')
-rw-r--r-- | zen/file_handling.cpp | 6 | ||||
-rw-r--r-- | zen/win_ver.h | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/zen/file_handling.cpp b/zen/file_handling.cpp index 0b544ed5..cf92f346 100644 --- a/zen/file_handling.cpp +++ b/zen/file_handling.cpp @@ -928,7 +928,7 @@ namespace void copySecurityContext(const Zstring& source, const Zstring& target, ProcSymlink procSl) //throw FileError { security_context_t contextSource = nullptr; - const int rv = procSl == SYMLINK_FOLLOW ? + const int rv = procSl == ProcSymlink::FOLLOW ? ::getfilecon(source.c_str(), &contextSource) : ::lgetfilecon(source.c_str(), &contextSource); if (rv < 0) @@ -943,7 +943,7 @@ void copySecurityContext(const Zstring& source, const Zstring& target, ProcSymli { security_context_t contextTarget = nullptr; - const int rv2 = procSl == SYMLINK_FOLLOW ? + const int rv2 = procSl == ProcSymlink::FOLLOW ? ::getfilecon(target.c_str(), &contextTarget) : ::lgetfilecon(target.c_str(), &contextTarget); if (rv2 < 0) @@ -961,7 +961,7 @@ void copySecurityContext(const Zstring& source, const Zstring& target, ProcSymli } } - const int rv3 = procSl == SYMLINK_FOLLOW ? + const int rv3 = procSl == ProcSymlink::FOLLOW ? ::setfilecon(target.c_str(), contextSource) : ::lsetfilecon(target.c_str(), contextSource); if (rv3 < 0) diff --git a/zen/win_ver.h b/zen/win_ver.h index 8797b596..766c0ee9 100644 --- a/zen/win_ver.h +++ b/zen/win_ver.h @@ -54,7 +54,7 @@ inline std::uint64_t getOsVersion() { OSVERSIONINFO osvi = {}; - osvi.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); + osvi.dwOSVersionInfoSize = sizeof(osvi); if (!::GetVersionEx(&osvi)) //38 ns per call! (yes, that's nano!) -> we do NOT miss C++11 thread safe statics right now... return 0; return toBigOsNumber(osvi.dwMajorVersion, osvi.dwMinorVersion); |