Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/windirstat/llfio.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'programs/key-value-store/main.cpp')
-rw-r--r--programs/key-value-store/main.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/programs/key-value-store/main.cpp b/programs/key-value-store/main.cpp
index 6f388bb1..101fa8b8 100644
--- a/programs/key-value-store/main.cpp
+++ b/programs/key-value-store/main.cpp
@@ -45,7 +45,7 @@ namespace stackoverflow
if(!_fh)
{
// Fetch the error code
- std::error_code ec = _fh.error();
+ std::error_code ec = _fh.error().ec;
// Did we fail due to file not found?
// It is *very* important to note that ec contains the *original* error code which could
// be POSIX, or Win32 or NT kernel error code domains. However we can always compare,
@@ -69,7 +69,7 @@ namespace stackoverflow
file_handle::io_result<file_handle::buffers_type> _buffers_read = read(fh, {reqs, 0});
if(!_buffers_read)
{
- std::error_code ec = _fh.error();
+ std::error_code ec = _fh.error().ec;
std::cerr << "Reading the file " << path << " failed with " << ec.message() << std::endl;
}
// Same as before, either throw any error or unpack the value returned