aboutsummaryrefslogtreecommitdiff
path: root/src/hostlist/hostlist-client.c
diff options
context:
space:
mode:
authorMatthias Wachs <wachs@net.in.tum.de>2010-04-16 07:58:56 +0000
committerMatthias Wachs <wachs@net.in.tum.de>2010-04-16 07:58:56 +0000
commite3ba93b28f79cd7dd16a605e1077a95490bf132c (patch)
treeaa1ff0d6280e0a4498f0055c6ae6a3b256c601cd /src/hostlist/hostlist-client.c
parentb09ccc6d3a24229af41b2ac0253262c8532e0e38 (diff)
downloadgnunet-e3ba93b28f79cd7dd16a605e1077a95490bf132c.tar.gz
gnunet-e3ba93b28f79cd7dd16a605e1077a95490bf132c.zip
removed peer from hostlist structure
Diffstat (limited to 'src/hostlist/hostlist-client.c')
-rw-r--r--src/hostlist/hostlist-client.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/hostlist/hostlist-client.c b/src/hostlist/hostlist-client.c
index 9fc1eb71e..9ad65fe35 100644
--- a/src/hostlist/hostlist-client.c
+++ b/src/hostlist/hostlist-client.c
@@ -51,8 +51,14 @@
51 */ 51 */
52struct Hostlist 52struct Hostlist
53{ 53{
54 /**
55 * previous entry, used to manage entries in a double linked list
56 */
54 struct Hostlist * prev; 57 struct Hostlist * prev;
55 58
59 /**
60 * next entry, used to manage entries in a double linked list
61 */
56 struct Hostlist * next; 62 struct Hostlist * next;
57 63
58 /** 64 /**
@@ -61,11 +67,6 @@ struct Hostlist
61 const char *hostlist_uri; 67 const char *hostlist_uri;
62 68
63 /** 69 /**
64 * Peer offering the hostlist. TO BE REMOVED.
65 */
66 struct GNUNET_PeerIdentity peer;
67
68 /**
69 * Value describing the quality of the hostlist, the bigger the better but (should) never < 0 70 * Value describing the quality of the hostlist, the bigger the better but (should) never < 0
70 * used for deciding which hostlist is replaced if MAX_NUMBER_HOSTLISTS in data structure is reached 71 * used for deciding which hostlist is replaced if MAX_NUMBER_HOSTLISTS in data structure is reached
71 * intial value = HOSTLIST_INITIAL 72 * intial value = HOSTLIST_INITIAL
@@ -78,22 +79,22 @@ struct Hostlist
78 /** 79 /**
79 * Time the hostlist advertisement was recieved and the entry was created 80 * Time the hostlist advertisement was recieved and the entry was created
80 */ 81 */
81 struct GNUNET_TIME_Absolute time_creation; 82 struct GNUNET_TIME_Absolute time_creation;
82 83
83 /** 84 /**
84 * Last time the hostlist was obtained 85 * Last time the hostlist was obtained
85 */ 86 */
86 struct GNUNET_TIME_Absolute time_last_usage; 87 struct GNUNET_TIME_Absolute time_last_usage;
87 88
88 /** 89 /**
89 * Number of HELLO messages obtained during last download 90 * Number of HELLO messages obtained during last download
90 */ 91 */
91 uint32_t hello_count; 92 uint32_t hello_count;
92 93
93 /** 94 /**
94 * Number of times the hostlist was obtained 95 * Number of times the hostlist was obtained
95 */ 96 */
96 uint32_t times_used; 97 uint32_t times_used;
97 98
98}; 99};
99 100
@@ -869,7 +870,6 @@ advertisement_handler (void *cls,
869 return GNUNET_OK; 870 return GNUNET_OK;
870 } 871 }
871 hostlist = GNUNET_malloc (sizeof (struct Hostlist) + uri_size); 872 hostlist = GNUNET_malloc (sizeof (struct Hostlist) + uri_size);
872 hostlist->peer = *peer;
873 hostlist->hostlist_uri = (const char*) &hostlist[1]; 873 hostlist->hostlist_uri = (const char*) &hostlist[1];
874 memcpy (&hostlist[1], uri, uri_size); 874 memcpy (&hostlist[1], uri, uri_size);
875 hostlist->time_creation = GNUNET_TIME_absolute_get(); 875 hostlist->time_creation = GNUNET_TIME_absolute_get();