mirror of
https://github.com/cesanta/mongoose.git
synced 2026-10-23 11:44:53 +00:00
squashed win32 warnings
This commit is contained in:
1 parent
2238951c18
commit
2436f9d6c3
1 file changed
+9
-4
+9
-4
@@ -874,7 +874,7 @@ int ns_server_poll(struct ns_server *server, int milli) {
|
||||
if (server->ctl[1] != INVALID_SOCKET &&
|
||||
FD_ISSET(server->ctl[1], &read_set)) {
|
||||
struct ctl_msg ctl_msg;
|
||||
int len = recv(server->ctl[1], &ctl_msg, sizeof(ctl_msg), 0);
|
||||
int len = recv(server->ctl[1], (char *) &ctl_msg, sizeof(ctl_msg), 0);
|
||||
send(server->ctl[1], ctl_msg.message, 1, 0);
|
||||
if (len >= (int) sizeof(ctl_msg.callback) && ctl_msg.callback != NULL) {
|
||||
ns_iterate(server, ctl_msg.callback, ctl_msg.message);
|
||||
@@ -992,8 +992,9 @@ void ns_server_wakeup_ex(struct ns_server *server, ns_callback_t cb,
|
||||
len < sizeof(ctl_msg.message)) {
|
||||
ctl_msg.callback = cb;
|
||||
memcpy(ctl_msg.message, data, len);
|
||||
send(server->ctl[0], &ctl_msg, offsetof(struct ctl_msg, message) + len, 0);
|
||||
recv(server->ctl[0], &len, 1, 0);
|
||||
send(server->ctl[0], (char *) &ctl_msg,
|
||||
offsetof(struct ctl_msg, message) + len, 0);
|
||||
recv(server->ctl[0], (char *) &len, 1, 0);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4252,6 +4253,10 @@ static void try_parse(struct connection *conn) {
|
||||
}
|
||||
}
|
||||
|
||||
static void proxy_from_client_to_target_host(struct connection *conn) {
|
||||
ns_forward(conn->ns_conn, conn->endpoint.nc);
|
||||
}
|
||||
|
||||
static void on_recv_data(struct connection *conn) {
|
||||
struct iobuf *io = &conn->ns_conn->recv_iobuf;
|
||||
|
||||
@@ -4275,7 +4280,7 @@ static void on_recv_data(struct connection *conn) {
|
||||
}
|
||||
|
||||
if (conn->endpoint_type == EP_PROXY && conn->endpoint.nc != NULL) {
|
||||
ns_forward(conn->ns_conn, conn->endpoint.nc);
|
||||
proxy_from_client_to_target_host(conn);
|
||||
}
|
||||
#ifndef MONGOOSE_NO_CGI
|
||||
if (conn->endpoint_type == EP_CGI && conn->endpoint.nc != NULL) {
|
||||
|
||||
Reference in new issue
Block a user