From 3e6df453129fd53ff09c342c4d7b4350afb8929a Mon Sep 17 00:00:00 2001 From: "Nathan S. Evans" Date: Thu, 5 Aug 2010 15:41:40 +0000 Subject: [PATCH] minor fixes --- src/dht/dhtlog.h | 2 +- src/dht/plugin_dhtlog_dummy.c | 2 +- src/dht/plugin_dhtlog_mysql.c | 6 +++--- src/dht/plugin_dhtlog_mysql_dump.c | 2 +- src/dht/test_dht_api.c | 4 ++-- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/dht/dhtlog.h b/src/dht/dhtlog.h index 36c81181b..ce3accb79 100644 --- a/src/dht/dhtlog.h +++ b/src/dht/dhtlog.h @@ -156,7 +156,7 @@ struct GNUNET_DHTLOG_Handle * * @return GNUNET_OK on success, GNUNET_SYSERR on failure */ - int (*insert_extended_topology) (struct GNUNET_PeerIdentity *first, struct GNUNET_PeerIdentity *second); + int (*insert_extended_topology) (const struct GNUNET_PeerIdentity *first, const struct GNUNET_PeerIdentity *second); /* * Update dhttests.trials table with total connections information diff --git a/src/dht/plugin_dhtlog_dummy.c b/src/dht/plugin_dhtlog_dummy.c index c90cc424b..173d77370 100644 --- a/src/dht/plugin_dhtlog_dummy.c +++ b/src/dht/plugin_dhtlog_dummy.c @@ -206,7 +206,7 @@ add_topology (int num_connections) * @return GNUNET_OK on success, GNUNET_SYSERR on failure */ int -add_extended_topology (struct GNUNET_PeerIdentity *first, struct GNUNET_PeerIdentity *second) +add_extended_topology (const struct GNUNET_PeerIdentity *first, const struct GNUNET_PeerIdentity *second) { return GNUNET_OK; } diff --git a/src/dht/plugin_dhtlog_mysql.c b/src/dht/plugin_dhtlog_mysql.c index 7798263c4..7b8c2e23f 100644 --- a/src/dht/plugin_dhtlog_mysql.c +++ b/src/dht/plugin_dhtlog_mysql.c @@ -575,7 +575,7 @@ get_node_uid (unsigned long long *nodeuid, const GNUNET_HashCode * peerHash) int ret; memset (rbind, 0, sizeof (rbind)); - rbind[0].buffer_type = MYSQL_TYPE_LONG; + rbind[0].buffer_type = MYSQL_TYPE_LONGLONG; rbind[0].buffer = nodeuid; rbind[0].is_unsigned = GNUNET_YES; @@ -587,7 +587,7 @@ get_node_uid (unsigned long long *nodeuid, const GNUNET_HashCode * peerHash) rbind, return_ok, NULL, - MYSQL_TYPE_LONG, + MYSQL_TYPE_LONGLONG, ¤t_trial, GNUNET_YES, MYSQL_TYPE_VAR_STRING, @@ -1287,7 +1287,7 @@ add_topology (int num_connections) * @return GNUNET_OK on success, GNUNET_SYSERR on failure */ int -add_extended_topology (struct GNUNET_PeerIdentity *first, struct GNUNET_PeerIdentity *second) +add_extended_topology (const struct GNUNET_PeerIdentity *first, const struct GNUNET_PeerIdentity *second) { int ret; unsigned long long first_uid; diff --git a/src/dht/plugin_dhtlog_mysql_dump.c b/src/dht/plugin_dhtlog_mysql_dump.c index 603e592e7..da3981841 100644 --- a/src/dht/plugin_dhtlog_mysql_dump.c +++ b/src/dht/plugin_dhtlog_mysql_dump.c @@ -200,7 +200,7 @@ add_topology (int num_connections) * @return GNUNET_OK on success, GNUNET_SYSERR on failure */ int -add_extended_topology (struct GNUNET_PeerIdentity *first, struct GNUNET_PeerIdentity *second) +add_extended_topology (const struct GNUNET_PeerIdentity *first, const struct GNUNET_PeerIdentity *second) { int ret; if (outfile == NULL) diff --git a/src/dht/test_dht_api.c b/src/dht/test_dht_api.c index eb34ae3c6..f7ee94fa4 100644 --- a/src/dht/test_dht_api.c +++ b/src/dht/test_dht_api.c @@ -34,7 +34,7 @@ #include "gnunet_dht_service.h" #include "gnunet_hello_lib.h" -#define VERBOSE GNUNET_NO +#define VERBOSE GNUNET_YES #define VERBOSE_ARM GNUNET_NO @@ -306,7 +306,7 @@ test_find_peer (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) retry_context.peer_ctx = peer; peer->find_peer_handle = - GNUNET_DHT_find_peer_start (peer->dht_handle, retry_context.next_timeout, 0, &hash, + GNUNET_DHT_find_peer_start (peer->dht_handle, retry_context.next_timeout, 1, &hash, &test_find_peer_processor, &retry_context, NULL, NULL); if (peer->find_peer_handle == NULL) -- 2.25.1