Remove unused alignup
function from util.h
This commit is contained in:
parent
d1e26d4e71
commit
121d6ad9db
1 changed files with 0 additions and 14 deletions
14
src/util.h
14
src/util.h
|
@ -46,20 +46,6 @@ static const int64_t CENT = 1000000;
|
|||
// This is needed because the foreach macro can't get over the comma in pair<t1, t2>
|
||||
#define PAIRTYPE(t1, t2) std::pair<t1, t2>
|
||||
|
||||
// Align by increasing pointer, must have extra space at end of buffer
|
||||
template <size_t nBytes, typename T>
|
||||
T* alignup(T* p)
|
||||
{
|
||||
union
|
||||
{
|
||||
T* ptr;
|
||||
size_t n;
|
||||
} u;
|
||||
u.ptr = p;
|
||||
u.n = (u.n + (nBytes-1)) & ~(nBytes-1);
|
||||
return u.ptr;
|
||||
}
|
||||
|
||||
#ifdef WIN32
|
||||
#define MSG_DONTWAIT 0
|
||||
|
||||
|
|
Loading…
Reference in a new issue