diff options
author | Willow Liquorice <willow@howhill.com> | 2022-08-26 02:43:02 +0100 |
---|---|---|
committer | Martin Schanzenbach <schanzen@gnunet.org> | 2022-08-30 09:41:49 +0200 |
commit | 9285bb74e36fc82d8b53e6fe29391714b916fb3c (patch) | |
tree | 2eda2715efcd9bb1c082ba68e183498df9697535 /src/cadet/gnunet-service-cadet_peer.c | |
parent | 586f250f1603572861af4b1bf570b3a253306bbf (diff) | |
download | gnunet-9285bb74e36fc82d8b53e6fe29391714b916fb3c.tar.gz gnunet-9285bb74e36fc82d8b53e6fe29391714b916fb3c.zip |
-DOC: First pass of new workflow over CADET subsystem.
Diffstat (limited to 'src/cadet/gnunet-service-cadet_peer.c')
-rw-r--r-- | src/cadet/gnunet-service-cadet_peer.c | 43 |
1 files changed, 0 insertions, 43 deletions
diff --git a/src/cadet/gnunet-service-cadet_peer.c b/src/cadet/gnunet-service-cadet_peer.c index 2437a3e1b..99669eb05 100644 --- a/src/cadet/gnunet-service-cadet_peer.c +++ b/src/cadet/gnunet-service-cadet_peer.c | |||
@@ -260,21 +260,6 @@ GCP_2s (const struct CadetPeer *cp) | |||
260 | } | 260 | } |
261 | 261 | ||
262 | 262 | ||
263 | /** | ||
264 | * Calculate how desirable a path is for @a cp if @a cp | ||
265 | * is at offset @a off. | ||
266 | * | ||
267 | * The 'desirability_table.c' program can be used to compute a list of | ||
268 | * sample outputs for different scenarios. Basically, we score paths | ||
269 | * lower if there are many alternatives, and higher if they are | ||
270 | * shorter than average, and very high if they are much shorter than | ||
271 | * average and without many alternatives. | ||
272 | * | ||
273 | * @param cp a peer reachable via a path | ||
274 | * @param off offset of @a cp in the path | ||
275 | * @return score how useful a path is to reach @a cp, | ||
276 | * positive scores mean path is more desirable | ||
277 | */ | ||
278 | double | 263 | double |
279 | GCP_get_desirability_of_path (struct CadetPeer *cp, | 264 | GCP_get_desirability_of_path (struct CadetPeer *cp, |
280 | unsigned int off) | 265 | unsigned int off) |
@@ -965,17 +950,6 @@ path_heap_cleanup (void *cls) | |||
965 | } | 950 | } |
966 | 951 | ||
967 | 952 | ||
968 | /** | ||
969 | * Try adding a @a path to this @a peer. If the peer already | ||
970 | * has plenty of paths, return NULL. | ||
971 | * | ||
972 | * @param cp peer to which the @a path leads to | ||
973 | * @param path a path looking for an owner; may not be fully initialized yet! | ||
974 | * @param off offset of @a cp in @a path | ||
975 | * @param force force attaching the path | ||
976 | * @return NULL if this peer does not care to become a new owner, | ||
977 | * otherwise the node in the peer's path heap for the @a path. | ||
978 | */ | ||
979 | struct GNUNET_CONTAINER_HeapNode * | 953 | struct GNUNET_CONTAINER_HeapNode * |
980 | GCP_attach_path (struct CadetPeer *cp, | 954 | GCP_attach_path (struct CadetPeer *cp, |
981 | struct CadetPeerPath *path, | 955 | struct CadetPeerPath *path, |
@@ -1287,16 +1261,6 @@ GCP_iterate_indirect_paths (struct CadetPeer *cp, | |||
1287 | } | 1261 | } |
1288 | 1262 | ||
1289 | 1263 | ||
1290 | /** | ||
1291 | * Iterate over the paths to @a cp where | ||
1292 | * @a cp is at distance @a dist from us. | ||
1293 | * | ||
1294 | * @param cp Peer to get path info. | ||
1295 | * @param dist desired distance of @a cp to us on the path | ||
1296 | * @param callback Function to call for every path. | ||
1297 | * @param callback_cls Closure for @a callback. | ||
1298 | * @return Number of iterated paths. | ||
1299 | */ | ||
1300 | unsigned int | 1264 | unsigned int |
1301 | GCP_iterate_paths_at (struct CadetPeer *cp, | 1265 | GCP_iterate_paths_at (struct CadetPeer *cp, |
1302 | unsigned int dist, | 1266 | unsigned int dist, |
@@ -1365,13 +1329,6 @@ hello_offer_done (void *cls) | |||
1365 | } | 1329 | } |
1366 | 1330 | ||
1367 | 1331 | ||
1368 | /** | ||
1369 | * We got a HELLO for a @a peer, remember it, and possibly | ||
1370 | * trigger adequate actions (like trying to connect). | ||
1371 | * | ||
1372 | * @param cp the peer we got a HELLO for | ||
1373 | * @param hello the HELLO to remember | ||
1374 | */ | ||
1375 | void | 1332 | void |
1376 | GCP_set_hello (struct CadetPeer *cp, | 1333 | GCP_set_hello (struct CadetPeer *cp, |
1377 | const struct GNUNET_HELLO_Message *hello) | 1334 | const struct GNUNET_HELLO_Message *hello) |