X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/7a8cd62135619ad52e05ae1c929ef07e166e4260..d55f9548c659a1e31267748bde0f8bc9846cd1d4:/examples/msg/bittorrent/connection.h diff --git a/examples/msg/bittorrent/connection.h b/examples/msg/bittorrent/connection.h index 807c709672..c2cb1264d6 100644 --- a/examples/msg/bittorrent/connection.h +++ b/examples/msg/bittorrent/connection.h @@ -9,16 +9,17 @@ * Contains the connection data of a peer. */ typedef struct s_connection { - int id; //Peer id - char *bitfield; //Fields + int id; //Peer id + char *bitfield; //Fields char *mailbox; int messages_count; double peer_speed; double last_unchoke; - int am_interested:1; //Indicates if we are interested in something the peer has - int interested:1; //Indicates if the peer is interested in one of our pieces - int choked_upload:1; //Indicates if the peer is choked for the current peer - int choked_download:1; //Indicates if the peer has choked the current peer + int current_piece; + int am_interested:1; //Indicates if we are interested in something the peer has + int interested:1; //Indicates if the peer is interested in one of our pieces + int choked_upload:1; //Indicates if the peer is choked for the current peer + int choked_download:1; //Indicates if the peer has choked the current peer } s_connection_t, *connection_t; /** * Build a new connection object from the peer id. @@ -35,4 +36,4 @@ void connection_add_speed_value(connection_t connection, double speed); * Frees a connection object */ void connection_free(void *data); -#endif /* BITTORRENT_CONNECTION_H_ */ +#endif /* BITTORRENT_CONNECTION_H_ */