From 0d6b02090e4b9e924392d1f340be9c7ac291df7c Mon Sep 17 00:00:00 2001 From: Takeshi Nakatani Date: Sat, 27 May 2023 20:33:43 +0900 Subject: [PATCH] Revert "Update curl.cpp: reduce memory cache use (#2157)" (#2170) This reverts commit 5b487f651aad9661a6e7d206b7404ebe47c7680a. --- src/curl.cpp | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/curl.cpp b/src/curl.cpp index 2ae9fa8..a5117b3 100644 --- a/src/curl.cpp +++ b/src/curl.cpp @@ -703,12 +703,7 @@ size_t S3fsCurl::DownloadWriteCallback(void* ptr, size_t size, size_t nmemb, voi } pCurl->partdata.startpos += totalwrite; pCurl->partdata.size -= totalwrite; - - // flush the file and clean the page cache - if (pCurl->partdata.size == 0){ - fdatasync(pCurl->partdata.fd); - } - + return totalwrite; }