[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] r37680 - gnunet/src/cadet
From: |
gnunet |
Subject: |
[GNUnet-SVN] r37680 - gnunet/src/cadet |
Date: |
Tue, 9 Aug 2016 12:00:31 +0200 |
Author: lynx
Date: 2016-08-09 12:00:31 +0200 (Tue, 09 Aug 2016)
New Revision: 37680
Modified:
gnunet/src/cadet/gnunet-cadet.c
Log:
GNUNET_CADET_close_port doesnt work as expected. Bailing out instead.
Modified: gnunet/src/cadet/gnunet-cadet.c
===================================================================
--- gnunet/src/cadet/gnunet-cadet.c 2016-08-09 10:00:29 UTC (rev 37679)
+++ gnunet/src/cadet/gnunet-cadet.c 2016-08-09 10:00:31 UTC (rev 37680)
@@ -401,15 +401,22 @@
enum GNUNET_CADET_ChannelOption options)
{
GNUNET_log (GNUNET_ERROR_TYPE_MESSAGE,
- "Incoming channel %p from %s on port %s\n",
- channel, GNUNET_i2s_full (initiator), GNUNET_h2s (port));
+ "Connected from %s\n",
+ GNUNET_i2s_full (initiator));
+ GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+ "Incoming channel %p on port %s\n",
+ channel, GNUNET_h2s (port));
if (NULL != ch)
{
GNUNET_break (0);
GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
"A channel already exists (%p)\n", ch);
- GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
- "Incoming channel %p on port %s\n", channel, GNUNET_h2s
(port));
+ /*
+ * From now on multiple channels will be sending data to us
+ * making the service of this command unpredictable in its
+ * current implementation. So for now let's just bail out.
+ */
+ GNUNET_SCHEDULER_shutdown();
return NULL;
}
if (0 == listen_port)
@@ -417,6 +424,10 @@
GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Not listening to channels\n");
return NULL;
}
+#if 0
+ // Closing the listen port currently breaks open connections.
+ // Is this an intentional departure from POSIX socket behavior?
+ //
if (NULL != lp) {
/* Now that we have our circuit up and running, let's not
* get confused by further incoming connect requests.
@@ -424,6 +435,7 @@
GNUNET_CADET_close_port (lp);
lp = NULL;
}
+#endif
ch = channel;
if (GNUNET_NO == echo)
{
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] r37680 - gnunet/src/cadet,
gnunet <=