aboutsummaryrefslogtreecommitdiff
path: root/src/fs/test_fs_download.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2011-04-03 13:47:56 +0000
committerChristian Grothoff <christian@grothoff.org>2011-04-03 13:47:56 +0000
commit8c23a185ee8d3c16c5552668dced851f82986041 (patch)
tree83f59d2190ffadcdc5643ba36578b2c6766b0e42 /src/fs/test_fs_download.c
parent1888cd7da7ae5e2c32faf66d3bef47ac7d225b35 (diff)
downloadgnunet-8c23a185ee8d3c16c5552668dced851f82986041.tar.gz
gnunet-8c23a185ee8d3c16c5552668dced851f82986041.zip
changing datastore API to support replication level --- not fully implemented --- and adding GNUNET_FS_BlockOptions struct to replace prio/anonymity/expiration+replication args
Diffstat (limited to 'src/fs/test_fs_download.c')
-rw-r--r--src/fs/test_fs_download.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/fs/test_fs_download.c b/src/fs/test_fs_download.c
index 5091c5a61..35592225a 100644
--- a/src/fs/test_fs_download.c
+++ b/src/fs/test_fs_download.c
@@ -295,6 +295,7 @@ run (void *cls,
295 struct GNUNET_FS_Uri *kuri; 295 struct GNUNET_FS_Uri *kuri;
296 struct GNUNET_FS_FileInformation *fi; 296 struct GNUNET_FS_FileInformation *fi;
297 size_t i; 297 size_t i;
298 struct GNUNET_FS_BlockOptions bo;
298 299
299 setup_peer (&p1, "test_fs_download_data.conf"); 300 setup_peer (&p1, "test_fs_download_data.conf");
300 fs = GNUNET_FS_start (cfg, 301 fs = GNUNET_FS_start (cfg,
@@ -309,6 +310,10 @@ run (void *cls,
309 buf[i] = GNUNET_CRYPTO_random_u32 (GNUNET_CRYPTO_QUALITY_WEAK, 256); 310 buf[i] = GNUNET_CRYPTO_random_u32 (GNUNET_CRYPTO_QUALITY_WEAK, 256);
310 meta = GNUNET_CONTAINER_meta_data_create (); 311 meta = GNUNET_CONTAINER_meta_data_create ();
311 kuri = GNUNET_FS_uri_ksk_create_from_args (2, keywords); 312 kuri = GNUNET_FS_uri_ksk_create_from_args (2, keywords);
313 bo.content_priority = 42;
314 bo.anonymity_level = 1;
315 bo.replication_level = 0;
316 bo.expiration_time = GNUNET_TIME_relative_to_absolute (LIFETIME);
312 fi = GNUNET_FS_file_information_create_from_data (fs, 317 fi = GNUNET_FS_file_information_create_from_data (fs,
313 "publish-context", 318 "publish-context",
314 FILESIZE, 319 FILESIZE,
@@ -316,9 +321,7 @@ run (void *cls,
316 kuri, 321 kuri,
317 meta, 322 meta,
318 GNUNET_NO, 323 GNUNET_NO,
319 1, 324 &bo);
320 42,
321 GNUNET_TIME_relative_to_absolute (LIFETIME));
322 GNUNET_FS_uri_destroy (kuri); 325 GNUNET_FS_uri_destroy (kuri);
323 GNUNET_CONTAINER_meta_data_destroy (meta); 326 GNUNET_CONTAINER_meta_data_destroy (meta);
324 GNUNET_assert (NULL != fi); 327 GNUNET_assert (NULL != fi);