/*--------------------------------------------------------------------------*/ BOOL freeDynamicGateway(char **dynLibName, char **gw_name, DynLibHandle *hlib, PROC_GATEWAY *ptrGateway) { if (*dynLibName) { FREE(*dynLibName); *dynLibName = NULL; } if (*gw_name) { FREE(*gw_name); *gw_name = NULL; } if (*hlib) { FreeDynLibrary(*hlib); *hlib = NULL; } if (*ptrGateway) { *ptrGateway = NULL; } if ((*hlib == NULL) && (*ptrGateway == NULL)) { return TRUE; } return FALSE; }
/*--------------------------------------------------------------------------*/ BOOL FreeDynLibJVM(void) { if (hLibJVM) { if (FreeDynLibrary(hLibJVM)) { ptr_JNI_GetDefaultJavaVMInitArgs = NULL; ptr_JNI_CreateJavaVM = NULL; ptr_JNI_GetCreatedJavaVMs = NULL; hLibJVM = NULL; bSymbolsLoaded = FALSE; return TRUE; } } return FALSE; }
/*---------------------------------------------------------------------------*/ void Sci_Delsym(int ishared) { int ish = Min(Max(0, ishared), ENTRYMAX - 1); int i = 0; for ( i = NEpoints - 1 ; i >= 0 ; i--) { if ( EP[i].Nshared == ish ) { int j; for ( j = i ; j <= NEpoints - 2 ; j++ ) { EP[j].epoint = EP[j + 1].epoint; EP[j].Nshared = EP[j + 1].Nshared; strcpy(EP[j].name, EP[j + 1].name); } NEpoints--; } } if ( hd[ish].ok != FALSE) { FreeDynLibrary ((DynLibHandle)hd[ish].shl); hd[ish].ok = FALSE; } }