Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependents: oldheating gps motorhome heating
Diff: tcp/http/httpshim/httpshim.c
- Revision:
- 155:22f249751106
- Parent:
- 154:ba9879b19d9f
- Child:
- 156:be12b8fd5b21
--- a/tcp/http/httpshim/httpshim.c Wed Jul 31 15:10:53 2019 +0000
+++ b/tcp/http/httpshim/httpshim.c Tue Aug 20 14:49:00 2019 +0000
@@ -13,8 +13,8 @@
void HttpShimRequest(int size, char* pRequestStream, uint32_t positionInRequestStream, char* pWebState, char* pTlsState, bool secure)
{
- if (secure) TlsRequest (pTlsState, pWebState, size, pRequestStream, positionInRequestStream);
- else HttpRequestFunction( pWebState, size, pRequestStream, positionInRequestStream);
+ if (secure) TlsRequest (pTlsState, pWebState, size, (uint8_t*)pRequestStream, positionInRequestStream);
+ else HttpRequestFunction( pWebState, size, pRequestStream, positionInRequestStream);
}
static bool tlsRequired;
@@ -24,7 +24,7 @@
if (tlsRequired) return TlsPoll (pTlsState, pWebState, clientFinished);
else return HttpPollFunction( pWebState, clientFinished);
}
-void HttpShimAddChar (char c)
+void HttpShimAddChar(char c)
{
if (tlsRequired) TlsAddChar(c);
else TcpBufAddChar(c);
@@ -36,5 +36,6 @@
}
bool HttpShimGetTrace()
{
- return HttpTrace;
+ if (tlsRequired) return TlsTrace;
+ else return HttpTrace;
}
\ No newline at end of file