fix superfluous \r\n after body

Fork of mbed-http by sandbox

Files at this revision

API Documentation at this revision

Comitter:
mpeylo
Date:
Wed Dec 20 14:25:11 2017 +0000
Parent:
21:fcd2bfd31a39
Commit message:
removing superfluous \r\n after HTTP body

Changed in this revision

source/http_request_builder.h Show annotated file Show diff for this revision Revisions of this file
--- a/source/http_request_builder.h	Thu Dec 14 16:19:22 2017 +0700
+++ b/source/http_request_builder.h	Wed Dec 20 14:25:11 2017 +0000
@@ -85,9 +85,6 @@
         // body
         size += body_size;
 
-        // extra newline
-        size += 2;
-
         // Now let's print it
         char* req = (char*)calloc(size + 1, 1);
         char* originalReq = req;
@@ -114,9 +111,6 @@
         }
         req += body_size;
 
-        sprintf(req, "\r\n");
-        req += 2;
-
         // Uncomment to debug...
         // printf("----- BEGIN REQUEST -----\n");
         // printf("%s", originalReq);