A
lgorithmique
N
umérique
D
istribuée
Public GIT Repository
projects
/
simgrid.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
sonar treats
[simgrid.git]
/
examples
/
msg
/
app-bittorrent
/
peer.c
diff --git
a/examples/msg/app-bittorrent/peer.c
b/examples/msg/app-bittorrent/peer.c
index
40a8256
..
959e523
100644
(file)
--- a/
examples/msg/app-bittorrent/peer.c
+++ b/
examples/msg/app-bittorrent/peer.c
@@
-454,7
+454,7
@@
void remove_current_piece(peer_t peer, connection_t remote_peer, unsigned int cu
void update_pieces_count_from_bitfield(peer_t peer, unsigned int bitfield)
{
for (int i = 0; i < FILE_PIECES; i++) {
void update_pieces_count_from_bitfield(peer_t peer, unsigned int bitfield)
{
for (int i = 0; i < FILE_PIECES; i++) {
- if (
(bitfield & (1U << i)
)) {
+ if (
bitfield & (1U << i
)) {
peer->pieces_count[i]++;
}
}
peer->pieces_count[i]++;
}
}