File tree Expand file tree Collapse file tree 3 files changed +14
-1
lines changed
Expand file tree Collapse file tree 3 files changed +14
-1
lines changed Original file line number Diff line number Diff line change 3333class TransportTraits
3434{
3535public:
36+ virtual ~TransportTraits ()
37+ {
38+ }
39+
3640 virtual std::unique_ptr<WiFiClient> create ()
3741 {
3842 return std::unique_ptr<WiFiClient>(new WiFiClient ());
@@ -624,6 +628,13 @@ int HTTPClient::writeToStream(Stream * stream)
624628 break ;
625629 }
626630
631+ // read trailing \r\n at the end of the chunk
632+ char buf[2 ];
633+ auto trailing_seq_len = _tcp->readBytes ((uint8_t *)buf, 2 );
634+ if (trailing_seq_len != 2 || buf[0 ] != ' \r ' || buf[1 ] != ' \n ' ) {
635+ return returnError (HTTPC_ERROR_READ_TIMEOUT);
636+ }
637+
627638 delay (0 );
628639 }
629640 } else {
Original file line number Diff line number Diff line change @@ -213,7 +213,7 @@ class UdpContext
213213 return size;
214214 }
215215
216- char peek ()
216+ int peek ()
217217 {
218218 if (!_rx_buf || _rx_buf_offset == _rx_buf->len )
219219 return -1 ;
Original file line number Diff line number Diff line change @@ -78,6 +78,8 @@ SECTIONS
7878 *(.sdata2 .*)
7979 *(.gnu .linkonce .s2 .*)
8080 *(.jcr )
81+ . = ALIGN (4 );
82+ _Pri_3_HandlerAddress = ABSOLUTE (.);
8183 _data_end = ABSOLUTE (.);
8284 } >dram0_0_seg :dram0_0_phdr
8385
You can’t perform that action at this time.
0 commit comments