nikhilm / qhttpserver

HTTP server implementation for Qt based on node.js' http parser

Home Page:http://kodeclutz.blogspot.com/2011/02/qhttpserver-web-apps-in-qt.html

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

cannot get the body data

icesword001 opened this issue · comments

the body has been empty

Please describe the situation more and show a sample of your code. qhttpserver is streaming, so it has to be used correctly (listen to the right events) to be able to access the body.

have a error in when compile source

error source(qhttpserver-master\http-parser\http_parser.c):
int hasBody = parser->flags & F_CHUNKED ||
(parser->content_length > 0 && parser->content_length != ULLONG_MAX);
if (parser->upgrade && (parser->method == HTTP_CONNECT ||
(parser->flags & F_SKIPBODY) || !hasBody)) {
/* Exit, the rest of the message is in a different protocol. */
UPDATE_STATE(NEW_MESSAGE());
CALLBACK_NOTIFY(message_complete);
RETURN((p - data) + 1);
}
the reason of error:
Error: C2143: syntax error : missing ';' before 'type'
Error: C2065: 'hasBody' : undeclared identifier