File tree 2 files changed +6
-2
lines changed
2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -189,6 +189,7 @@ void esp32FOTA::setConfig( FOTAConfig_t cfg )
189
189
_cfg.root_ca = cfg.root_ca ;
190
190
_cfg.pub_key = cfg.pub_key ;
191
191
_cfg.signature_len = cfg.signature_len ;
192
+ _cfg.allow_reuse = cfg.allow_reuse ;
192
193
}
193
194
194
195
@@ -206,7 +207,8 @@ void esp32FOTA::printConfig( FOTAConfig_t *cfg )
206
207
cfg->use_device_id ?" true" :" false" ,
207
208
cfg->root_ca ?" true" :" false" ,
208
209
cfg->pub_key ?" true" :" false" ,
209
- cfg->signature_len
210
+ cfg->signature_len ,
211
+ cfg->allow_reuse
210
212
);
211
213
}
212
214
@@ -364,7 +366,8 @@ bool esp32FOTA::setupHTTP( const char* url )
364
366
{
365
367
const char * rootcastr = nullptr ;
366
368
_http.setFollowRedirects (HTTPC_STRICT_FOLLOW_REDIRECTS);
367
-
369
+ _http.setReuse (_cfg.allow_reuse );
370
+
368
371
log_i (" Connecting to: %s" , url );
369
372
if ( String (url).startsWith (" https" ) ) {
370
373
if (!_cfg.unsafe ) {
Original file line number Diff line number Diff line change @@ -220,6 +220,7 @@ struct FOTAConfig_t
220
220
CryptoAsset* root_ca { nullptr };
221
221
CryptoAsset* pub_key { nullptr };
222
222
size_t signature_len {FW_SIGNATURE_LENGTH};
223
+ bool allow_reuse { true };
223
224
FOTAConfig_t () = default ;
224
225
};
225
226
You can’t perform that action at this time.
0 commit comments