1
0
mirror of https://github.com/lammertb/libhttp.git synced 2025-07-29 21:01:13 +03:00

Fix C++ build errors in Linux

This commit is contained in:
bel
2014-06-24 21:44:21 +02:00
parent 9899ee6090
commit 724753a7da
3 changed files with 13 additions and 8 deletions

View File

@ -9,6 +9,8 @@
#ifdef _WIN32
#include <Windows.h>
#else
#include <unistd.h>
#endif
#define DOCUMENT_ROOT "."

View File

@ -281,14 +281,8 @@ protected:
char * postData;
unsigned long postDataLen;
CivetConnection() {
postData = NULL;
postDataLen = 0;
}
~CivetConnection() {
free(postData);
}
CivetConnection();
~CivetConnection();
};
struct mg_context *context;

View File

@ -277,3 +277,12 @@ CivetServer::urlEncode(const char *src, size_t src_len, std::string &dst, bool a
}
}
}
CivetServer::CivetConnection::CivetConnection() {
postData = NULL;
postDataLen = 0;
}
CivetServer::CivetConnection::~CivetConnection() {
free(postData);
}