Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Energy, onHostDestruction: ensured ptr existence
[simgrid.git] / examples / msg / bittorrent / connection.h
index 807c709..418b638 100644 (file)
@@ -1,8 +1,9 @@
-/* Copyright (c) 2012. The SimGrid Team.
+/* Copyright (c) 2012-2014. The SimGrid Team.
  * All rights reserved.                                                     */
 
 /* This program is free software; you can redistribute it and/or modify it
  * under the terms of the license (GNU LGPL) which comes with this package. */
+
 #ifndef BITTORRENT_CONNECTION_H_
 #define BITTORRENT_CONNECTION_H_
 /**
@@ -15,6 +16,7 @@ typedef struct s_connection {
   int messages_count;
   double peer_speed;
   double last_unchoke;
+  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