From 863ff54097231ceae6e34908d843586adc83a44d Mon Sep 17 00:00:00 2001 From: Daniel Plasa Date: Tue, 26 May 2020 04:56:07 +0200 Subject: cleanup readme, undecided on the transfer buffer, work in progress on that --- espFtpServer.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'espFtpServer.cpp') diff --git a/espFtpServer.cpp b/espFtpServer.cpp index a6c705f..aa67fe3 100644 --- a/espFtpServer.cpp +++ b/espFtpServer.cpp @@ -1030,9 +1030,9 @@ int32_t FtpServer::allocateBuffer(int32_t desiredBytes) if (maxBlock - desiredBytes < 0) desiredBytes = maxBlock; - // leave at least (10% of heap) as reserve - if (maxHeap - desiredBytes < (maxHeap / 10)) - desiredBytes -= (maxHeap / 10); + // leave at least (20% of heap) as reserve + if (maxHeap - desiredBytes < (maxHeap / 5)) + desiredBytes -= (maxHeap / 5); // round down on 4byte bound desiredBytes &= ~3; -- cgit v1.2.3