From c05b51bbfcdf28573c4d0f9ee8cf6264d26f9a45 Mon Sep 17 00:00:00 2001
From: MPR <michel.promonet@free.fr>
Date: Thu, 16 Oct 2014 23:57:14 +0200
Subject: [PATCH] =?UTF-8?q?make=20compile=20with=20g++=20(fix=20invalid=20?=
 =?UTF-8?q?conversion=20from=20=E2=80=98void*=E2=80=99=20to=20=E2=80=98ns?=
 =?UTF-8?q?=5Fconnection*=E2=80=99)?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 mongoose.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/mongoose.c b/mongoose.c
index 5f20d6b2c..e55a5562f 100644
--- a/mongoose.c
+++ b/mongoose.c
@@ -4930,7 +4930,7 @@ void mg_copy_listeners(struct mg_server *s, struct mg_server *to) {
   struct ns_connection *c;
   for (c = ns_next(&s->ns_mgr, NULL); c != NULL; c = ns_next(&s->ns_mgr, c)) {
     struct ns_connection *tmp;
-    if ((c->flags & NSF_LISTENING) && (tmp = malloc(sizeof(*tmp))) != NULL) {
+    if ((c->flags & NSF_LISTENING) && (tmp = (ns_connection *)malloc(sizeof(*tmp))) != NULL) {
       memcpy(tmp, c, sizeof(*tmp));
       tmp->mgr = &to->ns_mgr;
       ns_add_conn(tmp->mgr, tmp);
-- 
GitLab