Fixes memory leak in HTTPClient by disabling connection reuse
This commit is contained in:
parent
b5f0472af4
commit
6cc4efca0a
@ -94,6 +94,7 @@ void sendToApi(void *parameter) {
|
|||||||
String octoToken = params->octoToken;
|
String octoToken = params->octoToken;
|
||||||
|
|
||||||
HTTPClient http;
|
HTTPClient http;
|
||||||
|
http.setReuse(false);
|
||||||
http.begin(spoolsUrl);
|
http.begin(spoolsUrl);
|
||||||
http.addHeader("Content-Type", "application/json");
|
http.addHeader("Content-Type", "application/json");
|
||||||
if (octoEnabled && octoToken != "") http.addHeader("X-Api-Key", octoToken);
|
if (octoEnabled && octoToken != "") http.addHeader("X-Api-Key", octoToken);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user