gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] r1038 - GNUnet/src/util


From: durner
Subject: [GNUnet-SVN] r1038 - GNUnet/src/util
Date: Sun, 26 Jun 2005 02:11:08 -0700 (PDT)

Author: durner
Date: 2005-06-26 02:11:05 -0700 (Sun, 26 Jun 2005)
New Revision: 1038

Modified:
   GNUnet/src/util/port.c
Log:
fix

Modified: GNUnet/src/util/port.c
===================================================================
--- GNUnet/src/util/port.c      2005-06-26 08:49:16 UTC (rev 1037)
+++ GNUnet/src/util/port.c      2005-06-26 09:11:05 UTC (rev 1038)
@@ -30,13 +30,20 @@
  */
 unsigned short getGNUnetPort() {
   unsigned short port;
+  char *setting;
+  
+  if (testConfigurationString("GNUNETD", "_MAGIC_", "YES"))
+               setting = "PORT";
+       else
+               setting = "CLIENT-PORT";
+  
 
   port = (unsigned short) getConfigurationInt("NETWORK",
-                                             "CLIENT-PORT");
+                                             setting);
   if (port == 0) { /* try lookup in services */
     errexit(_("Cannot determine port of gnunetd server. Define in 
configuration file in section '%s' under '%s'.\n"),
            "NETWORK",
-           "CLIENT-PORT");
+           setting);
   }
   return port;
 }





reply via email to

[Prev in Thread] Current Thread [Next in Thread]