File tree Expand file tree Collapse file tree 2 files changed +11
-11
lines changed
Expand file tree Collapse file tree 2 files changed +11
-11
lines changed Original file line number Diff line number Diff line change @@ -136,13 +136,13 @@ int Arduino_ESP32_OTA::download(const char * ota_url)
136136 port = 443 ;
137137 } else {
138138 DEBUG_ERROR (" %s: Failed to parse OTA URL %s" , __FUNCTION__, ota_url);
139- return static_cast <int >(Error::UrlParseError );
139+ return static_cast <int >(Error::UrlParse );
140140 }
141141
142142 if (!_client->connect (url.host_ .c_str (), port))
143143 {
144144 DEBUG_ERROR (" %s: Connection failure with OTA storage server %s" , __FUNCTION__, url.host_ .c_str ());
145- return static_cast <int >(Error::ServerConnectError );
145+ return static_cast <int >(Error::ServerConnect );
146146 }
147147
148148 _client->println (String (" GET " ) + url.path_ .c_str () + " HTTP/1.1" );
@@ -172,7 +172,7 @@ int Arduino_ESP32_OTA::download(const char * ota_url)
172172 if (!is_header_complete)
173173 {
174174 DEBUG_ERROR (" %s: Error receiving HTTP header %s" , __FUNCTION__, is_http_header_timeout ? " (timeout)" :" " );
175- return static_cast <int >(Error::HttpHeaderError );
175+ return static_cast <int >(Error::HttpHeader );
176176 }
177177
178178 /* Check HTTP response status code */
Original file line number Diff line number Diff line change @@ -63,17 +63,17 @@ class Arduino_ESP32_OTA
6363 None = 0 ,
6464 NoOtaStorage = -2 ,
6565 OtaStorageInit = -3 ,
66- OtaStorageEnd = -4 ,
67- UrlParseError = -5 ,
68- ServerConnectError = -6 ,
69- HttpHeaderError = -7 ,
66+ OtaHeaderLength = -5 ,
67+ OtaHeaderCrc = -6 ,
68+ OtaHeaterMagicNumber = -7 ,
7069 ParseHttpHeader = -8 ,
71- OtaHeaderLength = -9 ,
72- OtaHeaderCrc = -10 ,
73- OtaHeaterMagicNumber = -11 ,
70+ UrlParse = -9 ,
71+ ServerConnect = -10 ,
72+ HttpHeader = -11 ,
7473 OtaDownload = -12 ,
7574 OtaHeaderTimeout = -13 ,
76- HttpResponse = -14
75+ HttpResponse = -14 ,
76+ OtaStorageEnd = -15 ,
7777 };
7878
7979 Arduino_ESP32_OTA ();
You can’t perform that action at this time.
0 commit comments