mirror of
https://github.com/HDFGroup/hdf5.git
synced 2024-12-27 08:01:04 +08:00
[svn-r23368] Correct names and add includes for windows
This commit is contained in:
parent
ebfebfd7d5
commit
23635d656a
@ -286,7 +286,6 @@ H5PL_find(H5PL_type_t plugin_type, int type_id, char *dir, void **info)
|
||||
{
|
||||
char *pathname = NULL;
|
||||
struct dirent *dp = NULL;
|
||||
struct stat my_stat;
|
||||
|
||||
WIN32_FIND_DATA fdFile;
|
||||
HANDLE hFind = NULL;
|
||||
@ -375,7 +374,7 @@ H5PL_open(H5PL_type_t pl_type, char *libname, int pl_id, void **pl_info)
|
||||
/*fprintf(stderr, "not open dl library: %s\n", H5PL_CLR_ERR);*/
|
||||
HGOTO_DONE(ret_value)
|
||||
|
||||
H5PL_CLR_ERR; /*clear error*/
|
||||
H5PL_CLR_ERROR; /*clear error*/
|
||||
|
||||
/* Return a handle for the function H5PL_get_plugin_info in the dynamic library.
|
||||
* The plugin library is suppose to define this function. */
|
||||
@ -448,7 +447,7 @@ fprintf(stderr, "%s: H5PL_table_used_g=%d, id=%d\n", FUNC, H5PL_table_used_g, (H
|
||||
for(i=0; i<H5PL_table_used_g; i++) {
|
||||
if((plugin_type == (H5PL_table_g[i]).pl_type) && (type_id == (H5PL_table_g[i]).pl_id)) {
|
||||
if(NULL == (H5PL_get_plugin_info = H5PL_GET_LIB_FUNC((H5PL_table_g[i]).handle, "H5PL_get_plugin_info")))
|
||||
HGOTO_ERROR(H5E_DATATYPE, H5E_CANTGET, FAIL, "can't get function: %s", H5PL_CLR_ERR)
|
||||
HGOTO_ERROR(H5E_DATATYPE, H5E_CANTGET, FAIL, "can't get function: %s", H5PL_CLR_ERROR)
|
||||
|
||||
if(NULL == (plugin_info = (*H5PL_get_plugin_info)()))
|
||||
HGOTO_ERROR(H5E_DATATYPE, H5E_CANTGET, FAIL, "can't get plugin info")
|
||||
|
@ -48,7 +48,7 @@
|
||||
#define H5PL_ERROR DWORD dw; char *error
|
||||
|
||||
/* Clear error - nothing to do */
|
||||
#define H5PLG_CLR_ERROR
|
||||
#define H5PL_CLR_ERROR
|
||||
|
||||
/* Print error message */
|
||||
#define H5PL_CHECK_ERR(R) { \
|
||||
|
@ -26,6 +26,19 @@
|
||||
/* Private headers needed by this file */
|
||||
#include "H5private.h" /* Generic Functions */
|
||||
|
||||
#ifdef H5_HAVE_WIN32_API
|
||||
/* The following two defines must be before any windows headers are included */
|
||||
#define WIN32_LEAN_AND_MEAN /* Exclude rarely-used stuff from Windows headers */
|
||||
#define NOGDI /* Exclude Graphic Display Interface macros */
|
||||
|
||||
#ifdef H5_HAVE_WINSOCK2_H
|
||||
#include <winsock2.h>
|
||||
#endif
|
||||
|
||||
#include <windows.h>
|
||||
|
||||
#endif /*H5_HAVE_WIN32_API*/
|
||||
|
||||
#ifdef H5_HAVE_DLFCN_H
|
||||
#include <dlfcn.h>
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user