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: HTTPClient_IFTTT_Maker_post_HelloWorld
Fork of HTTPClient by
Diff: HTTPClient.cpp
- Revision:
- 18:277279a1891e
- Parent:
- 17:679e15a3d3db
- Child:
- 19:a0d9edb403e5
--- a/HTTPClient.cpp Fri May 02 13:13:39 2014 +0000
+++ b/HTTPClient.cpp Wed May 07 16:48:10 2014 +0000
@@ -381,15 +381,16 @@
if(keyEnd != NULL)
{
*keyEnd = '\0';
-
- if(sscanf(buf, "%31c", key) == 1)
+ if(strlen(buf) < 32)
{
+ strcpy(key, buf);
n++;
char* valueStart = keyEnd + 2;
if( (valueStart - buf) < crlfPos )
{
- if(sscanf(valueStart, "%31c", value) == 1)
- {
+ if(strlen(valueStart) < 32)
+ {
+ strcpy(value, valueStart);
n++;
}
}
