| 146 | } |
| 147 | |
| 148 | static void set_preferred_peer(struct seeker *seeker, struct peer *peer) |
| 149 | { |
| 150 | if (seeker->preferred_peer_softref |
| 151 | && seeker->preferred_peer_softref != peer) { |
| 152 | clear_softref(seeker, &seeker->preferred_peer_softref); |
| 153 | set_softref(seeker, &seeker->preferred_peer_softref, peer); |
| 154 | } |
| 155 | } |
| 156 | |
| 157 | /* Get a random peer, but try our preferred peer first, if any. This |
| 158 | * biasses us to the peer that told us of unexpected gossip. */ |
no outgoing calls
no test coverage detected