if (!objects_list->dl_module) { path = __lc_path(objects_list->dl_name, lc_dir); #if defined(hpux) objects_list->dl_module = shl_load(path, BIND_DEFERRED, 0L); #else objects_list->dl_module = dlopen(path, RTLD_LAZY); #endif Xfree(path); if (!objects_list->dl_module) continue; } #if defined(hpux) getsyms_cnt = shl_getsymbols(objects_list->dl_module, TYPE_PROCEDURE, EXPORT_SYMBOLS, malloc, &symbols);
if (!open_object (objects_list, lc_dir)) continue;
_XlcDynamicLoad(lc_name)     const char *lc_name;#endif{    XLCd lcd = (XLCd)NULL;    XLCd (*lc_loader)() = (XLCd(*)())NULL;    char *path;    int count;    XI18NObjectsList objects_list;    char lc_dir[BUFSIZE];#if defined(hpux)    int getsyms_cnt, i;    struct shl_symbol *symbols;#endif    if (lc_name == NULL) return (XLCd)NULL;    if (_XlcLocaleDirName(lc_dir, (char *)lc_name) == (char*)NULL)	return (XLCd)NULL;    resolve_object(lc_dir, lc_name);    objects_list = xi18n_objects_list;    count = lc_count;    for (; count-- > 0; objects_list++) {        if (objects_list->type != XLC_OBJECT ||	    strcmp(objects_list->locale_name, lc_name)) continue;	if (!objects_list->dl_module) {	  path = __lc_path(objects_list->dl_name, lc_dir);#if defined(hpux)	  objects_list->dl_module = shl_load(path, BIND_DEFERRED, 0L);#else	  objects_list->dl_module = dlopen(path, RTLD_LAZY);#endif	  Xfree(path);	  if (!objects_list->dl_module) continue;	}#if defined(hpux)	getsyms_cnt = shl_getsymbols(objects_list->dl_module, TYPE_PROCEDURE,		EXPORT_SYMBOLS, malloc, &symbols);	for(i=0; i<getsyms_cnt; i++) {	    if(!strcmp(symbols[i].name, objects_list->open)) {		lc_loader = symbols[i].value;		break;	    }	}	if(getsyms_cnt > 0) {	    free(symbols);	}#else	lc_loader = (XLCd(*)())try_both_dlsym(objects_list->dl_module,					      objects_list->open);#endif	if (!lc_loader) continue;	lcd = (*lc_loader)(lc_name);	if (lcd != (XLCd)NULL) {	    break;	}#if defined(hpux)	shl_unload(objects_list->dl_module);#else	dlclose(objects_list->dl_module);#endif	objects_list->dl_module = NULL;    }    return (XLCd)lcd;}