diff options
author | ivanmorozov <[email protected]> | 2022-02-10 16:47:34 +0300 |
---|---|---|
committer | Daniil Cherednik <[email protected]> | 2022-02-10 16:47:34 +0300 |
commit | 464ba3814a83db4f2d5327393b0b6eaf0c86bfd7 (patch) | |
tree | c0748b5dcbade83af788c0abfa89c0383d6b779c /util/system/error.cpp | |
parent | cba5d9a444e2cfe105f55ccda66cd21d50440017 (diff) |
Restoring authorship annotation for <[email protected]>. Commit 2 of 2.
Diffstat (limited to 'util/system/error.cpp')
-rw-r--r-- | util/system/error.cpp | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/util/system/error.cpp b/util/system/error.cpp index f02b3e800f8..f778ec42cbe 100644 --- a/util/system/error.cpp +++ b/util/system/error.cpp @@ -26,19 +26,19 @@ void ClearLastSystemError() { int LastSystemError() { #if defined(_win_) - int ret = GetLastError(); + int ret = GetLastError(); - if (ret) + if (ret) return ret; - ret = WSAGetLastError(); - - if (ret) - return ret; - // when descriptors number are over maximum, errno set in this variable - ret = *(_errno()); - return ret; - + ret = WSAGetLastError(); + + if (ret) + return ret; + // when descriptors number are over maximum, errno set in this variable + ret = *(_errno()); + return ret; + #else return errno; #endif |