diff options
Diffstat (limited to 'router/router.cpp')
-rw-r--r-- | router/router.cpp | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/router/router.cpp b/router/router.cpp index e2ba91d1..1fdf45ac 100644 --- a/router/router.cpp +++ b/router/router.cpp @@ -20,7 +20,7 @@ enum LogLevel LogLevel = LogLevel_Error; FILE *LogFile; -static void LoadDriverList(void); +static void LoadDriverList(); BOOL APIENTRY DllMain(HINSTANCE, DWORD reason, void*) @@ -313,7 +313,7 @@ static int GetLoadedModuleDirectory(const WCHAR *name, WCHAR *moddir, DWORD leng return 1; } -void LoadDriverList(void) +void LoadDriverList() { WCHAR dll_path[MAX_PATH+1] = L""; WCHAR cwd_path[MAX_PATH+1] = L""; @@ -361,7 +361,7 @@ void LoadDriverList(void) PtrIntMap::~PtrIntMap() { std::lock_guard<std::mutex> maplock{mLock}; - al_free(mKeys); + free(mKeys); mKeys = nullptr; mValues = nullptr; mSize = 0; @@ -382,8 +382,7 @@ ALenum PtrIntMap::insert(void *key, int value) ALsizei newcap{mCapacity ? (mCapacity<<1) : 4}; if(newcap > mCapacity) newkeys = static_cast<void**>( - al_calloc(16, (sizeof(mKeys[0])+sizeof(mValues[0]))*newcap) - ); + calloc(newcap, sizeof(mKeys[0])+sizeof(mValues[0]))); if(!newkeys) return AL_OUT_OF_MEMORY; auto newvalues = reinterpret_cast<int*>(&newkeys[newcap]); @@ -393,7 +392,7 @@ ALenum PtrIntMap::insert(void *key, int value) std::copy_n(mKeys, mSize, newkeys); std::copy_n(mValues, mSize, newvalues); } - al_free(mKeys); + free(mKeys); mKeys = newkeys; mValues = newvalues; mCapacity = newcap; |