mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-28 06:13:31 +01:00
r13946@catbus: nickm | 2007-07-27 16:09:31 -0400
Fix median_int for platforms where sizeof(int)!=sizeof(time_t) svn:r10949
This commit is contained in:
parent
a5477c7bb9
commit
0e5d8925d9
@ -121,7 +121,7 @@ median_int(smartlist_t *ints)
|
||||
tor_assert(smartlist_len(ints));
|
||||
smartlist_sort(ints, _compare_ints);
|
||||
idx = (smartlist_len(ints)-1)/2;
|
||||
return *(time_t*)smartlist_get(ints, idx);
|
||||
return *(int*)smartlist_get(ints, idx);
|
||||
}
|
||||
|
||||
/** Given a vote <b>vote</b> (not a consensus!), return its associated
|
||||
|
Loading…
Reference in New Issue
Block a user