aboutsummaryrefslogtreecommitdiff
path: root/src/psyc/psyc_api.c
diff options
context:
space:
mode:
authorGabor X Toth <*@tg-x.net>2016-01-06 12:28:47 +0000
committerGabor X Toth <*@tg-x.net>2016-01-06 12:28:47 +0000
commit80d2de6cdc4d253c7fbc6a4bc067d856aab9cca9 (patch)
tree86e33af618c53b82afd0cb4855d7da595fcd5acd /src/psyc/psyc_api.c
parent7d1dfe26d99376a341bb150eb89ba717bb883077 (diff)
downloadgnunet-80d2de6cdc4d253c7fbc6a4bc067d856aab9cca9.tar.gz
gnunet-80d2de6cdc4d253c7fbc6a4bc067d856aab9cca9.zip
psyc/social: local join flag; social service: leave place, save _file
Diffstat (limited to 'src/psyc/psyc_api.c')
-rw-r--r--src/psyc/psyc_api.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/psyc/psyc_api.c b/src/psyc/psyc_api.c
index 9392deeef..8152fc47f 100644
--- a/src/psyc/psyc_api.c
+++ b/src/psyc/psyc_api.c
@@ -847,7 +847,8 @@ GNUNET_PSYC_master_get_channel (struct GNUNET_PSYC_Master *master)
847 * notification on failure (as the channel may simply take days to approve, 847 * notification on failure (as the channel may simply take days to approve,
848 * and disapproval is simply being ignored). 848 * and disapproval is simply being ignored).
849 * 849 *
850 * @param cfg Configuration to use. 850 * @param cfg
851 * Configuration to use.
851 * @param channel_key ECC public key that identifies the channel we wish to join. 852 * @param channel_key ECC public key that identifies the channel we wish to join.
852 * @param slave_key ECC private-public key pair that identifies the slave, and 853 * @param slave_key ECC private-public key pair that identifies the slave, and
853 * used by multicast to sign the join request and subsequent unicast 854 * used by multicast to sign the join request and subsequent unicast
@@ -873,8 +874,9 @@ GNUNET_PSYC_master_get_channel (struct GNUNET_PSYC_Master *master)
873 */ 874 */
874struct GNUNET_PSYC_Slave * 875struct GNUNET_PSYC_Slave *
875GNUNET_PSYC_slave_join (const struct GNUNET_CONFIGURATION_Handle *cfg, 876GNUNET_PSYC_slave_join (const struct GNUNET_CONFIGURATION_Handle *cfg,
876 const struct GNUNET_CRYPTO_EddsaPublicKey *channel_key, 877 const struct GNUNET_CRYPTO_EddsaPublicKey *channel_pub_key,
877 const struct GNUNET_CRYPTO_EcdsaPrivateKey *slave_key, 878 const struct GNUNET_CRYPTO_EcdsaPrivateKey *slave_key,
879 enum GNUNET_PSYC_SlaveJoinFlags flags,
878 const struct GNUNET_PeerIdentity *origin, 880 const struct GNUNET_PeerIdentity *origin,
879 uint32_t relay_count, 881 uint32_t relay_count,
880 const struct GNUNET_PeerIdentity *relays, 882 const struct GNUNET_PeerIdentity *relays,
@@ -898,10 +900,11 @@ GNUNET_PSYC_slave_join (const struct GNUNET_CONFIGURATION_Handle *cfg,
898 req = GNUNET_malloc (sizeof (*req) + relay_size + join_msg_size); 900 req = GNUNET_malloc (sizeof (*req) + relay_size + join_msg_size);
899 req->header.size = htons (sizeof (*req) + relay_size + join_msg_size); 901 req->header.size = htons (sizeof (*req) + relay_size + join_msg_size);
900 req->header.type = htons (GNUNET_MESSAGE_TYPE_PSYC_SLAVE_JOIN); 902 req->header.type = htons (GNUNET_MESSAGE_TYPE_PSYC_SLAVE_JOIN);
901 req->channel_key = *channel_key; 903 req->channel_pub_key = *channel_pub_key;
902 req->slave_key = *slave_key; 904 req->slave_key = *slave_key;
903 req->origin = *origin; 905 req->origin = *origin;
904 req->relay_count = htonl (relay_count); 906 req->relay_count = htonl (relay_count);
907 req->flags = htonl (flags);
905 908
906 if (0 < relay_size) 909 if (0 < relay_size)
907 memcpy (&req[1], relays, relay_size); 910 memcpy (&req[1], relays, relay_size);