-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Closed
Labels
type: bugwaiting for feedbackWaiting on additional info. If it's not received, the issue may be closed.Waiting on additional info. If it's not received, the issue may be closed.
Description
Basic Infos
ESP8266HTTPClient: TCP socket hangs up at sending larger files with.
With stable version is was working just fine even with very large files so it was introduced lately.
Hardware
Hardware: ESP-WROOM2
Core Version: latest github
Description
Im using HTTPClient.sendRequest("POST", file).
With smaller files <1kB it works just fine. With larger files ~50kB it failes with HTTPC_ERROR_SEND_PAYLOAD_FAILED after a long timeout.
The error occurs in this part of the code:
L492-499 ESP8266HTTPClient.cpp
bytesWrite = _tcp->write((const uint8_t *) (buff + bytesWrite), leftBytes);
bytesWritten += bytesWrite;
if(bytesWrite != leftBytes) {
DEBUG_HTTPCLIENT("[HTTP-Client][sendRequest] short write, asked for %d but got %d failed.\n", leftBytes, bytesWrite);
free(buff);
return returnError(HTTPC_ERROR_SEND_PAYLOAD_FAILED);
}
Output
"short write, asked for 1460 but got 0 failed"
So there is no more data send via "_tcp->write()" after ~4kB
Any major change in the WiFiClient which may cause this?
Metadata
Metadata
Assignees
Labels
type: bugwaiting for feedbackWaiting on additional info. If it's not received, the issue may be closed.Waiting on additional info. If it's not received, the issue may be closed.