From 8b137c57c5043848d6e611833cea5e3638bada9f Mon Sep 17 00:00:00 2001 From: jl777 Date: Fri, 10 Mar 2017 10:21:29 +0200 Subject: [PATCH] Test --- basilisk/basilisk_swap.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/basilisk/basilisk_swap.c b/basilisk/basilisk_swap.c index 516509e15..7dd4c70eb 100755 --- a/basilisk/basilisk_swap.c +++ b/basilisk/basilisk_swap.c @@ -1176,7 +1176,13 @@ uint32_t basilisk_swapsend(struct supernet_info *myinfo,struct basilisk_swap *sw { printf("sentbytes.%d vs offset.%d\n",sentbytes,offset); if ( sentbytes < 0 ) + { + if ( swap->pushsock >= 0 ) + nn_close(swap->pushsock), swap->pushsock = -1; + if ( swap->subsock >= 0 ) + nn_close(swap->subsock), swap->subsock = -1; swap->connected = 0; + } } //else printf("send.[%d] %x offset.%d datalen.%d [%llx]\n",sentbytes,msgbits,offset,datalen,*(long long *)data); free(buf);