fix
authorChristian Grothoff <christian@grothoff.org>
Mon, 5 Oct 2009 10:20:33 +0000 (10:20 +0000)
committerChristian Grothoff <christian@grothoff.org>
Mon, 5 Oct 2009 10:20:33 +0000 (10:20 +0000)
src/util/crypto_rsa.c
src/util/resolver_api.c

index 99e4bc1c1cd07ac4af70b50ce8e07e4bd01f7655..ef2e328e9a56185ef3291043393725b96b460c44 100644 (file)
@@ -642,12 +642,12 @@ GNUNET_CRYPTO_rsa_key_create_from_file (const char *filename)
       if (GNUNET_YES != GNUNET_DISK_file_test (filename))
         {
           /* eh, what!? File we opened is now gone!? */
-          GNUNET_log_strerror_file (GNUNET_ERROR_TYPE_ERROR,
+          GNUNET_log_strerror_file (GNUNET_ERROR_TYPE_WARNING,
                                     "stat", filename);
           if (GNUNET_YES != GNUNET_DISK_file_unlock (fd, 0, sizeof (struct RsaPrivateKeyBinaryEncoded)))
             GNUNET_log_strerror_file (GNUNET_ERROR_TYPE_WARNING,
                                       "fcntl", filename);
-          GNUNET_assert (0 == GNUNET_DISK_file_close (fd));
+          GNUNET_assert (GNUNET_OK == GNUNET_DISK_file_close (fd));
 
           return NULL;
         }
index 2b8997fac6798382e0b541cc919285990f2e355e..b86e5c6669e0165df0e2b548b6e7a91ec1835964 100644 (file)
@@ -124,6 +124,10 @@ check_config (const struct GNUNET_CONFIGURATION_Handle *cfg)
 
 /**
  * Convert IP address to string without DNS resolution.
+ *
+ * @param sa the address 
+ * @param salen number of bytes in sa
+ * @return address as a string, NULL on error
  */
 static char *
 no_resolve (const struct sockaddr *sa, socklen_t salen)
@@ -160,6 +164,12 @@ no_resolve (const struct sockaddr *sa, socklen_t salen)
 }
 
 
+/**
+ * FIXME
+ *
+ * @param cls FIXME
+ * @param msg FIXME
+ */
 static void
 handle_address_response (void *cls, const struct GNUNET_MessageHeader *msg)
 {
@@ -224,6 +234,14 @@ handle_address_response (void *cls, const struct GNUNET_MessageHeader *msg)
 }
 
 
+/**
+ * FIXME
+ *
+ * @param cls FIXME
+ * @param size number of bytes available in buf
+ * @param buf target buffer, NULL on error
+ * @return number of bytes written to buf
+ */
 static size_t
 transmit_get_ip (void *cls, size_t size, void *buf)
 {
@@ -396,16 +414,45 @@ GNUNET_RESOLVER_ip_get (struct GNUNET_SCHEDULER_Handle *sched,
 }
 
 
+/**
+ * FIXME.
+ */
 struct GetHostnameContext
 {
+
+  /**
+   * FIXME.
+   */
   GNUNET_RESOLVER_HostnameCallback callback;
+  
+  /**
+   * FIXME.
+   */
   void *cls;
+  
+  /**
+   * FIXME.
+   */ 
   struct GNUNET_RESOLVER_GetMessage *msg;
+  
+  /**
+   * FIXME.
+   */  
   struct GNUNET_CLIENT_Connection *client;
+  
+  /**
+   * FIXME.
+   */ 
   struct GNUNET_TIME_Absolute timeout;
 };
 
 
+/**
+ * FIXME.
+ *
+ * @param cls FIXME
+ * @param msg FIXME
+ */
 static void
 handle_hostname_response (void *cls, const struct GNUNET_MessageHeader *msg)
 {
@@ -455,6 +502,14 @@ handle_hostname_response (void *cls, const struct GNUNET_MessageHeader *msg)
 }
 
 
+/**
+ * FIXME
+ *
+ * @param cls FIXME
+ * @param size number of bytes available in buf
+ * @param buf target buffer, NULL on error
+ * @return number of bytes written to buf
+ */
 static size_t
 transmit_get_hostname (void *cls, size_t size, void *buf)
 {