Skip to content

Commit ad538b1

Browse files
minor clean up
1 parent 8e20486 commit ad538b1

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

SRC/api/packages.cpp

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,6 @@ httpGET_File(char const* URL, char const* page, unsigned int port, const char* f
5454
int
5555
getLibraryFunction(const char* libName, const char* funcName, void** libHandle, void** funcHandle) {
5656

57-
int result = 0;
58-
5957
*libHandle = NULL;
6058
*funcHandle = NULL;
6159

@@ -198,7 +196,7 @@ getLibraryFunction(const char* libName, const char* funcName, void** libHandle,
198196
funcPtr = (setGlobalPointersFunction)GetProcAddress((HMODULE)hLib, "setGlobalPointers");
199197
if (funcPtr == 0) {
200198
FreeLibrary((HMODULE)hLib);
201-
return -2;
199+
return -3;
202200
}
203201

204202
// invoke pointer function
@@ -319,7 +317,7 @@ getLibraryFunction(const char* libName, const char* funcName, void** libHandle,
319317
if (funcPtr == NULL) {
320318
dlclose(*libHandle);
321319
delete[] localLibName;
322-
return -1;
320+
return -2;
323321
}
324322

325323
*funcHandle = funcPtr;
@@ -344,5 +342,5 @@ getLibraryFunction(const char* libName, const char* funcName, void** libHandle,
344342

345343
#endif
346344

347-
return result;
345+
return 0;
348346
}

0 commit comments

Comments
 (0)