diff options
author | 2013-08-12 13:56:55 +0000 | |
---|---|---|
committer | 2013-08-12 13:56:55 +0000 | |
commit | 5f184e36d63c2e9af0f96e7d98ad2fd14b0f3c68 (patch) | |
tree | 5c204c5c180776ee7ccbeacdae732ec82e9dc64b /src/lib/web/mongoose.c | |
parent | 59837a1e7df63b744d6168faeb3a78520b4b6cdd (diff) |
Moved webengine into separate file, added callbacks for websockets and made example for triggering ui on driver change, also added json for game driver (nw)
Diffstat (limited to 'src/lib/web/mongoose.c')
-rw-r--r-- | src/lib/web/mongoose.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/lib/web/mongoose.c b/src/lib/web/mongoose.c index aad9c735bc5..7f5dee1a48c 100644 --- a/src/lib/web/mongoose.c +++ b/src/lib/web/mongoose.c @@ -19,6 +19,7 @@ // THE SOFTWARE. #define NO_SSL +#define USE_WEBSOCKET #if defined(_WIN32) #define SETSOCKOPT_CAST const char * @@ -4052,7 +4053,7 @@ static void read_websocket(struct mg_connection *conn) { if (header_len > 0) { // Allocate space to hold websocket payload data = mem; - if (data_len > sizeof(mem) && (data = malloc(data_len)) == NULL) { + if (data_len > sizeof(mem) && (data = (char*)malloc(data_len)) == NULL) { // Allocation failed, exit the loop and then close the connection // TODO: notify user about the failure break; |