From: Christian Grothoff Date: Mon, 5 Oct 2009 10:20:33 +0000 (+0000) Subject: fix X-Git-Tag: initial-import-from-subversion-38251~23382 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=54227c4878ea1c20ed0b2719d773e6d55ea3ae69;p=oweals%2Fgnunet.git fix --- diff --git a/src/util/crypto_rsa.c b/src/util/crypto_rsa.c index 99e4bc1c1..ef2e328e9 100644 --- a/src/util/crypto_rsa.c +++ b/src/util/crypto_rsa.c @@ -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; } diff --git a/src/util/resolver_api.c b/src/util/resolver_api.c index 2b8997fac..b86e5c666 100644 --- a/src/util/resolver_api.c +++ b/src/util/resolver_api.c @@ -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) {