diff options
author | Christian Grothoff <christian@grothoff.org> | 2011-09-27 21:06:11 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2011-09-27 21:06:11 +0000 |
commit | 65b243be0941da4896afd842deda48cd0ce488e2 (patch) | |
tree | 019901e73101b13f9602fa8118aa7503e9ee7d32 /src/fs | |
parent | 94f1bfcb5f933ea09b9e4d066685709eba423951 (diff) | |
download | gnunet-65b243be0941da4896afd842deda48cd0ce488e2.tar.gz gnunet-65b243be0941da4896afd842deda48cd0ce488e2.zip |
DHT api switch adjustments
Diffstat (limited to 'src/fs')
-rw-r--r-- | src/fs/gnunet-service-fs_pr.c | 21 | ||||
-rw-r--r-- | src/fs/gnunet-service-fs_put.c | 2 |
2 files changed, 13 insertions, 10 deletions
diff --git a/src/fs/gnunet-service-fs_pr.c b/src/fs/gnunet-service-fs_pr.c index d47d28ce6..dd59170a2 100644 --- a/src/fs/gnunet-service-fs_pr.c +++ b/src/fs/gnunet-service-fs_pr.c | |||
@@ -941,10 +941,10 @@ test_put_load_too_high (uint32_t priority) | |||
941 | * @param cls closure | 941 | * @param cls closure |
942 | * @param exp when will this value expire | 942 | * @param exp when will this value expire |
943 | * @param key key of the result | 943 | * @param key key of the result |
944 | * @param get_path NULL-terminated array of pointers | 944 | * @param get_path peers on reply path (or NULL if not recorded) |
945 | * to the peers on reverse GET path (or NULL if not recorded) | 945 | * @param get_path_length number of entries in get_path |
946 | * @param put_path NULL-terminated array of pointers | 946 | * @param put_path peers on the PUT path (or NULL if not recorded) |
947 | * to the peers on the PUT path (or NULL if not recorded) | 947 | * @param put_path_length number of entries in get_path |
948 | * @param type type of the result | 948 | * @param type type of the result |
949 | * @param size number of bytes in data | 949 | * @param size number of bytes in data |
950 | * @param data pointer to the result data | 950 | * @param data pointer to the result data |
@@ -952,8 +952,10 @@ test_put_load_too_high (uint32_t priority) | |||
952 | static void | 952 | static void |
953 | handle_dht_reply (void *cls, struct GNUNET_TIME_Absolute exp, | 953 | handle_dht_reply (void *cls, struct GNUNET_TIME_Absolute exp, |
954 | const GNUNET_HashCode * key, | 954 | const GNUNET_HashCode * key, |
955 | const struct GNUNET_PeerIdentity *const *get_path, | 955 | const struct GNUNET_PeerIdentity *get_path, |
956 | const struct GNUNET_PeerIdentity *const *put_path, | 956 | unsigned int get_path_length, |
957 | const struct GNUNET_PeerIdentity *put_path, | ||
958 | unsigned int put_path_length, | ||
957 | enum GNUNET_BLOCK_Type type, size_t size, const void *data) | 959 | enum GNUNET_BLOCK_Type type, size_t size, const void *data) |
958 | { | 960 | { |
959 | struct GSF_PendingRequest *pr = cls; | 961 | struct GSF_PendingRequest *pr = cls; |
@@ -1032,9 +1034,10 @@ GSF_dht_lookup_ (struct GSF_PendingRequest *pr) | |||
1032 | pr->gh = | 1034 | pr->gh = |
1033 | GNUNET_DHT_get_start (GSF_dht, GNUNET_TIME_UNIT_FOREVER_REL, | 1035 | GNUNET_DHT_get_start (GSF_dht, GNUNET_TIME_UNIT_FOREVER_REL, |
1034 | pr->public_data.type, &pr->public_data.query, | 1036 | pr->public_data.type, &pr->public_data.query, |
1035 | DEFAULT_GET_REPLICATION, | 1037 | 5 /* DEFAULT_GET_REPLICATION */, |
1036 | GNUNET_DHT_RO_DEMULTIPLEX_EVERYWHERE, pr->bf, | 1038 | GNUNET_DHT_RO_DEMULTIPLEX_EVERYWHERE, |
1037 | pr->mingle, xquery, xquery_size, &handle_dht_reply, | 1039 | /* FIXME: can no longer pass pr->bf/pr->mingle... */ |
1040 | xquery, xquery_size, &handle_dht_reply, | ||
1038 | pr); | 1041 | pr); |
1039 | } | 1042 | } |
1040 | 1043 | ||
diff --git a/src/fs/gnunet-service-fs_put.c b/src/fs/gnunet-service-fs_put.c index 5771b5665..4910144d1 100644 --- a/src/fs/gnunet-service-fs_put.c +++ b/src/fs/gnunet-service-fs_put.c | |||
@@ -161,7 +161,7 @@ process_dht_put_content (void *cls, const GNUNET_HashCode * key, size_t size, | |||
161 | "Retrieved block `%s' of type %u for DHT PUT\n", GNUNET_h2s (key), | 161 | "Retrieved block `%s' of type %u for DHT PUT\n", GNUNET_h2s (key), |
162 | type); | 162 | type); |
163 | #endif | 163 | #endif |
164 | GNUNET_DHT_put (GSF_dht, key, DEFAULT_PUT_REPLICATION, GNUNET_DHT_RO_NONE, | 164 | GNUNET_DHT_put (GSF_dht, key, 5 /* DEFAULT_PUT_REPLICATION */, GNUNET_DHT_RO_NONE, |
165 | type, size, data, expiration, GNUNET_TIME_UNIT_FOREVER_REL, | 165 | type, size, data, expiration, GNUNET_TIME_UNIT_FOREVER_REL, |
166 | &delay_dht_put_blocks, po); | 166 | &delay_dht_put_blocks, po); |
167 | } | 167 | } |