Revision c642734a som/PeerSet/peerset_ops.c

View differences:

som/PeerSet/peerset_ops.c
72 72
struct peer *peerset_get_peer(const struct peerset *h, struct nodeID *id)
73 73
{
74 74
  int i = peerset_check(h,id);
75
  return (i<0) ? &(h->elements[i]) : NULL;
75
  return (i<0) ? NULL : &(h->elements[i]);
76 76
}
77 77

  
78 78
int peerset_check(const struct peerset *h, const struct nodeID *id)

Also available in: Unified diff