1
0
Fork 0
mirror of https://github.com/warmcat/libwebsockets.git synced 2025-03-09 00:00:04 +01:00

use compatible_close for sockets

Signed-off-by: Andy Green <andy.green@linaro.org>
This commit is contained in:
Andy Green 2013-10-22 06:49:30 +08:00
parent 0c0bf4a985
commit 8b2d6f0ee7

View file

@ -2174,7 +2174,7 @@ libwebsocket_create_context(struct lws_context_creation_info *info)
if (n < 0) {
lwsl_err("ERROR on binding to port %d (%d %d)\n",
info->port, n, errno);
close(sockfd);
compatible_close(sockfd);
goto bail;
}
@ -2182,7 +2182,7 @@ libwebsocket_create_context(struct lws_context_creation_info *info)
sizeof(struct libwebsocket));
if (wsi == NULL) {
lwsl_err("Out of mem\n");
close(sockfd);
compatible_close(sockfd);
goto bail;
}
memset(wsi, 0, sizeof(struct libwebsocket));