1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-06-13 13:01:55 +03:00

Remove useless call to setContentLength() (#6715)

* Update ESP8266WebServer-impl.h

Remove useless call to setContentLength()

* Fix warning unused param
This commit is contained in:
Develo
2019-11-05 21:50:52 -03:00
committed by GitHub
parent 2abcd16efb
commit ffa9e3c7c2

View File

@ -533,7 +533,7 @@ template <typename ServerType>
void ESP8266WebServerTemplate<ServerType>::_streamFileCore(const size_t fileSize, const String &fileName, const String &contentType)
{
using namespace mime;
setContentLength(fileSize);
(void)fileSize;
if (fileName.endsWith(String(FPSTR(mimeTable[gz].endsWith))) &&
contentType != String(FPSTR(mimeTable[gz].mimeType)) &&
contentType != String(FPSTR(mimeTable[none].mimeType))) {