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
Use empty() to check for container emptiness.
[simgrid.git]
/
examples
/
deprecated
/
java
/
app
/
bittorrent
/
Peer.java
diff --git
a/examples/deprecated/java/app/bittorrent/Peer.java
b/examples/deprecated/java/app/bittorrent/Peer.java
index
83f36cc
..
3bd30bf
100644
(file)
--- a/
examples/deprecated/java/app/bittorrent/Peer.java
+++ b/
examples/deprecated/java/app/bittorrent/Peer.java
@@
-395,7
+395,7
@@
public class Peer extends Process {
// Update the list of current choked and unchoked peers, using the choke algorithm
private void updateChokedPeers() {
round = (round + 1) % 3;
- if (peers.
size() == 0
) {
+ if (peers.
isEmpty()
) {
return;
}
//remove a peer from the list