diff options
Diffstat (limited to 'netfs/fuse/fuseFiles.cpp')
-rw-r--r-- | netfs/fuse/fuseFiles.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/netfs/fuse/fuseFiles.cpp b/netfs/fuse/fuseFiles.cpp index c50dcf1..eeb5423 100644 --- a/netfs/fuse/fuseFiles.cpp +++ b/netfs/fuse/fuseFiles.cpp @@ -115,8 +115,8 @@ namespace NetFS { } } - template<typename Rtn, typename F> - inline Rtn + template<typename F> + inline auto FuseApp::waitOnWriteRangeAndThen(size_t s, off_t o, const OpenFilePtr & of, const F & f) { const auto key = OpenFile::range(o, s); @@ -186,7 +186,7 @@ namespace NetFS { blockSizeIterate( blockSizes, [&ops, &o, &of, &remote, blockOffset = 0U](safe<size_t> blockSize) mutable { ops.emplace_back(blockOffset, - waitOnWriteRangeAndThen<std::future<Buffer>>( + waitOnWriteRangeAndThen( blockSize, o, of, [o, blockSize, &remote](const auto &) { return remote->readAsync(o, blockSize); })); @@ -226,8 +226,7 @@ namespace NetFS { auto bytes = reinterpret_cast<const ::Ice::Byte *>(buf); if (fcr->Async) { blockSizeIterate(of->blockSizes(s), [&bytes, &o, &remote, &of](safe<size_t> blockSize) { - waitOnWriteRangeAndThen<void>( - blockSize, o, of, [o, blockSize, bytes, &of, remote](const auto & key) { + waitOnWriteRangeAndThen(blockSize, o, of, [o, blockSize, bytes, &of, remote](const auto & key) { auto p = std::make_shared<OpenFile::WriteState>(); of->bg.insert({key, p}); remote->writeAsync( |