|
|
@ -163,15 +163,13 @@ extern char * sn_selection_criterion_str (selection_criterion_str_t out, peer_in |
|
|
|
} |
|
|
|
memset(out, 0, SN_SELECTION_CRITERION_BUF_SIZE); |
|
|
|
|
|
|
|
if(peer->selection_criterion > 0) { |
|
|
|
#ifndef SN_SELECTION_RTT |
|
|
|
snprintf(out, SN_SELECTION_CRITERION_BUF_SIZE, |
|
|
|
(int16_t)(peer->selection_criterion) >= 0 ? "load = %8d" : |
|
|
|
"", peer->selection_criterion); |
|
|
|
snprintf(out, SN_SELECTION_CRITERION_BUF_SIZE, "load = %8d", peer->selection_criterion); |
|
|
|
#else |
|
|
|
snprintf(out, SN_SELECTION_CRITERION_BUF_SIZE, |
|
|
|
(int16_t)(peer->selection_criterion) >= 0 ? "rtt = %6d ms" : |
|
|
|
"", peer->selection_criterion); |
|
|
|
snprintf(out, SN_SELECTION_CRITERION_BUF_SIZE, "rtt = %6d ms", peer->selection_criterion); |
|
|
|
#endif |
|
|
|
} |
|
|
|
|
|
|
|
return out; |
|
|
|
} |
|
|
|