Skip to content

Commit 7b661f1

Browse files
committed
Updating Civetweb
1 parent 72039fa commit 7b661f1

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

src/civetweb/civetweb.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3338,6 +3338,7 @@ mg_get_server_ports(const struct mg_context *ctx,
33383338
ports[cnt].is_ssl = ctx->listening_sockets[i].is_ssl;
33393339
ports[cnt].is_redirect = ctx->listening_sockets[i].ssl_redir;
33403340
ports[cnt].is_optional = ctx->listening_sockets[i].is_optional;
3341+
ports[cnt].is_bound = ctx->listening_sockets[i].sock != INVALID_SOCKET;
33413342

33423343
if (ctx->listening_sockets[i].lsa.sa.sa_family == AF_INET) {
33433344
/* IPv4 */

src/civetweb/civetweb.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -725,7 +725,7 @@ struct mg_server_port {
725725
int is_ssl; /* https port: 0 = no, 1 = yes */
726726
int is_redirect; /* redirect all requests: 0 = no, 1 = yes */
727727
int is_optional; /* optional: 0 = no, 1 = yes */
728-
int _reserved2;
728+
int is_bound; /* bound: 0 = no, 1 = yes, relevant for optional ports */
729729
int _reserved3;
730730
int _reserved4;
731731
};

0 commit comments

Comments
 (0)