[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] r19408 - gnunet/src/exit
From: |
gnunet |
Subject: |
[GNUnet-SVN] r19408 - gnunet/src/exit |
Date: |
Wed, 25 Jan 2012 21:20:07 +0100 |
Author: grothoff
Date: 2012-01-25 21:20:07 +0100 (Wed, 25 Jan 2012)
New Revision: 19408
Modified:
gnunet/src/exit/gnunet-helper-exit.c
Log:
-quiet exit helper
Modified: gnunet/src/exit/gnunet-helper-exit.c
===================================================================
--- gnunet/src/exit/gnunet-helper-exit.c 2012-01-25 20:16:08 UTC (rev
19407)
+++ gnunet/src/exit/gnunet-helper-exit.c 2012-01-25 20:20:07 UTC (rev
19408)
@@ -55,6 +55,12 @@
#include "gnunet_protocols.h"
/**
+ * Should we print (interesting|debug) messages that can happen during
+ * normal operation?
+ */
+#define DEBUG GNUNET_NO
+
+/**
* Maximum size of a GNUnet message (GNUNET_SERVER_MAX_MESSAGE_SIZE)
*/
#define MAX_SIZE 65536
@@ -476,7 +482,9 @@
}
else if (0 == buftun_size)
{
+#if DEBUG
fprintf (stderr, "EOF on tun\n");
+#endif
shutdown (fd_tun, SHUT_RD);
shutdown (1, SHUT_WR);
read_open = 0;
@@ -498,7 +506,10 @@
if (-1 == written)
{
- fprintf (stderr, "write-error to stdout: %s\n", strerror (errno));
+#if !DEBUG
+ if (errno != EPIPE)
+#endif
+ fprintf (stderr, "write-error to stdout: %s\n", strerror (errno));
shutdown (fd_tun, SHUT_RD);
shutdown (1, SHUT_WR);
read_open = 0;
@@ -529,7 +540,9 @@
}
else if (0 == bufin_size)
{
+#if DEBUG
fprintf (stderr, "EOF on stdin\n");
+#endif
shutdown (0, SHUT_RD);
shutdown (fd_tun, SHUT_WR);
write_open = 0;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] r19408 - gnunet/src/exit,
gnunet <=