diff options
author | Nathan S. Evans <evans@in.tum.de> | 2010-03-12 08:38:10 +0000 |
---|---|---|
committer | Nathan S. Evans <evans@in.tum.de> | 2010-03-12 08:38:10 +0000 |
commit | d82a838ef2250f344e8846cdf24504c2cde0f0d4 (patch) | |
tree | 7e07634c284fd49e5e92723792ca6f315171588f /src/dv/dv.h | |
parent | 40cdfd2a094ad1e1d39d619c84ba04a18637ebef (diff) | |
download | gnunet-d82a838ef2250f344e8846cdf24504c2cde0f0d4.tar.gz gnunet-d82a838ef2250f344e8846cdf24504c2cde0f0d4.zip |
non-compiling, but getting there
Diffstat (limited to 'src/dv/dv.h')
-rw-r--r-- | src/dv/dv.h | 50 |
1 files changed, 49 insertions, 1 deletions
diff --git a/src/dv/dv.h b/src/dv/dv.h index 3063bc917..10120a4b0 100644 --- a/src/dv/dv.h +++ b/src/dv/dv.h | |||
@@ -54,7 +54,7 @@ struct GNUNET_DV_MessageReceived | |||
54 | /** | 54 | /** |
55 | * The sender of the message | 55 | * The sender of the message |
56 | */ | 56 | */ |
57 | struct GNUNET_PeerIdentity *sender; | 57 | struct GNUNET_PeerIdentity sender; |
58 | 58 | ||
59 | /** | 59 | /** |
60 | * The message that was sent | 60 | * The message that was sent |
@@ -156,6 +156,54 @@ struct GNUNET_DV_SendMessage | |||
156 | 156 | ||
157 | }; | 157 | }; |
158 | 158 | ||
159 | /** | ||
160 | * Message that gets sent between nodes updating dv infos | ||
161 | */ | ||
162 | typedef struct | ||
163 | { | ||
164 | struct GNUNET_MessageHeader header; | ||
165 | |||
166 | /** | ||
167 | * Cost from received from node to neighbor node, takes distance into account | ||
168 | */ | ||
169 | unsigned int cost GNUNET_PACKED; | ||
170 | |||
171 | /** | ||
172 | * Identity of neighbor we learned information about | ||
173 | */ | ||
174 | struct GNUNET_PeerIdentity neighbor; | ||
175 | |||
176 | /** | ||
177 | * Neighbor ID to use when sending to this peer | ||
178 | */ | ||
179 | unsigned int neighbor_id GNUNET_PACKED; | ||
180 | |||
181 | } p2p_dv_MESSAGE_NeighborInfo; | ||
182 | |||
183 | /** | ||
184 | * Message that gets sent between nodes carrying information | ||
185 | */ | ||
186 | typedef struct | ||
187 | { | ||
188 | struct GNUNET_MessageHeader header; | ||
189 | |||
190 | /** | ||
191 | * Identity of peer that ultimately sent the message. | ||
192 | * Should be looked up in the set of 'neighbor_id's of | ||
193 | * the referring peer. | ||
194 | */ | ||
195 | unsigned int sender GNUNET_PACKED; | ||
196 | |||
197 | /** | ||
198 | * Identity of neighbor this message is going to. Should | ||
199 | * be looked up in the set of our own identifiers for | ||
200 | * neighbors! | ||
201 | */ | ||
202 | unsigned int recipient GNUNET_PACKED; | ||
203 | |||
204 | } p2p_dv_MESSAGE_Data; | ||
205 | |||
206 | |||
159 | struct GNUNET_DV_Handle * | 207 | struct GNUNET_DV_Handle * |
160 | GNUNET_DV_connect (struct GNUNET_SCHEDULER_Handle *sched, | 208 | GNUNET_DV_connect (struct GNUNET_SCHEDULER_Handle *sched, |
161 | const struct GNUNET_CONFIGURATION_Handle *cfg, | 209 | const struct GNUNET_CONFIGURATION_Handle *cfg, |