summaryrefslogtreecommitdiff
path: root/libpiano/src/http.c
diff options
context:
space:
mode:
Diffstat (limited to 'libpiano/src/http.c')
-rw-r--r--libpiano/src/http.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libpiano/src/http.c b/libpiano/src/http.c
index d33a4e5..f21b839 100644
--- a/libpiano/src/http.c
+++ b/libpiano/src/http.c
@@ -43,6 +43,10 @@ PianoReturn_t PianoHttpPost (WaitressHandle_t *waith, const char *postData,
PianoReturn_t pRet = PIANO_RET_NET_ERROR;
char *reqPostData = PianoEncryptString (postData);
+ if (reqPostData == NULL) {
+ return PIANO_RET_OUT_OF_MEMORY;
+ }
+
waith->extraHeaders = "Content-Type: text/xml\r\n";
waith->postData = reqPostData;
waith->method = WAITRESS_METHOD_POST;