diff options
author | ermolovd <ermolovd@yandex-team.ru> | 2022-02-10 16:47:53 +0300 |
---|---|---|
committer | Daniil Cherednik <dcherednik@yandex-team.ru> | 2022-02-10 16:47:53 +0300 |
commit | 2a4a975b112fa0fa138abc7457fe67e0e1e7fd02 (patch) | |
tree | c0748b5dcbade83af788c0abfa89c0383d6b779c /util/system/file.cpp | |
parent | b91bcef7c99a119b0846479ef71bfab4beec72ca (diff) | |
download | ydb-2a4a975b112fa0fa138abc7457fe67e0e1e7fd02.tar.gz |
Restoring authorship annotation for <ermolovd@yandex-team.ru>. Commit 2 of 2.
Diffstat (limited to 'util/system/file.cpp')
-rw-r--r-- | util/system/file.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/util/system/file.cpp b/util/system/file.cpp index 76b033cee2..4a261d020c 100644 --- a/util/system/file.cpp +++ b/util/system/file.cpp @@ -425,8 +425,8 @@ bool TFileHandle::Flush() noexcept { */ return ok || GetLastError() == ERROR_INVALID_HANDLE; #elif defined(_unix_) - int ret = ::fsync(Fd_); - + int ret = ::fsync(Fd_); + /* * Ignore EROFS, EINVAL - fd is bound to a special file * (PIPE, FIFO, or socket) which does not support synchronization. @@ -449,10 +449,10 @@ bool TFileHandle::FlushData() noexcept { return false; } - int ret = ::fdatasync(Fd_); - + int ret = ::fdatasync(Fd_); + // Same loginc in error handling as for fsync above. - return ret == 0 || errno == EROFS || errno == EINVAL; + return ret == 0 || errno == EROFS || errno == EINVAL; #else return Flush(); #endif |