summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2007-08-23 23:19:18 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2007-08-23 23:19:18 (GMT)
commit51073136ce409884c772b712a69f1264a50f8252 (patch)
tree6b322b9d0dedffed42a1abffb2aaef4f56cae6ea /src
parent14ce8811f7bf82571312163d5105852bd545fa4e (diff)
downloadhdf5-51073136ce409884c772b712a69f1264a50f8252.zip
hdf5-51073136ce409884c772b712a69f1264a50f8252.tar.gz
hdf5-51073136ce409884c772b712a69f1264a50f8252.tar.bz2
[svn-r14109] Description:
Make certain to define the API function and typedef version macros in all situations. Tested on: FreeBSD/32 6.2 (duty) Mac OS X/32 10.4.10 (amazon)
Diffstat (limited to 'src')
-rw-r--r--src/H5Eint.c10
-rw-r--r--src/H5version.h24
2 files changed, 29 insertions, 5 deletions
diff --git a/src/H5Eint.c b/src/H5Eint.c
index 95075d7..66fba91 100644
--- a/src/H5Eint.c
+++ b/src/H5Eint.c
@@ -68,7 +68,7 @@ typedef struct H5E_print_t {
/* Local Prototypes */
/********************/
#ifndef H5_NO_DEPRECATED_SYMBOLS
-static herr_t H5E_walk1_cb(unsigned n, const H5E_error1_t *err_desc,
+static herr_t H5E_walk1_cb(int n, H5E_error1_t *err_desc,
void *client_data);
#endif /* H5_NO_DEPRECATED_SYMBOLS */
static herr_t H5E_walk2_cb(unsigned n, const H5E_error2_t *err_desc,
@@ -215,7 +215,7 @@ H5E_get_msg(const H5E_msg_t *msg, H5E_type_t *type, char *msg_str, size_t size)
*-------------------------------------------------------------------------
*/
static herr_t
-H5E_walk1_cb(unsigned n, const H5E_error1_t *err_desc, void *client_data)
+H5E_walk1_cb(int n, H5E_error1_t *err_desc, void *client_data)
{
H5E_print_t *eprint = (H5E_print_t *)client_data;
FILE *stream; /* I/O stream to print output to */
@@ -291,7 +291,7 @@ H5E_walk1_cb(unsigned n, const H5E_error1_t *err_desc, void *client_data)
have_desc=0;
/* Print error message */
- fprintf(stream, "%*s#%03u: %s line %u in %s()%s%s\n",
+ fprintf(stream, "%*s#%03d: %s line %u in %s()%s%s\n",
H5E_INDENT, "", n, err_desc->file_name, err_desc->line,
err_desc->func_name, (have_desc ? ": " : ""),
(have_desc ? err_desc->desc : ""));
@@ -548,7 +548,7 @@ H5E_walk(const H5E_t *estack, H5E_direction_t direction, const H5E_walk_op_t *op
old_err.desc = estack->slot[i].desc;
old_err.line = estack->slot[i].line;
- status = (op->u.func1)((unsigned)i, &old_err, client_data);
+ status = (op->u.func1)(i, &old_err, client_data);
} /* end for */
} /* end if */
else {
@@ -562,7 +562,7 @@ H5E_walk(const H5E_t *estack, H5E_direction_t direction, const H5E_walk_op_t *op
old_err.desc = estack->slot[i].desc;
old_err.line = estack->slot[i].line;
- status = (op->u.func1)((unsigned)(estack->nused - (size_t)(i + 1)), &old_err, client_data);
+ status = (op->u.func1)((int)(estack->nused - (size_t)(i + 1)), &old_err, client_data);
} /* end for */
} /* end else */
diff --git a/src/H5version.h b/src/H5version.h
index fd534b1..e22ea8c 100644
--- a/src/H5version.h
+++ b/src/H5version.h
@@ -88,6 +88,9 @@
/*************/
#if !defined(H5Eclear_vers) || H5Eclear_vers == 2
+#ifndef H5Eclear_vers
+#define H5Eclear_vers 2
+#endif /* H5Eclear_vers */
#define H5Eclear H5Eclear2
#elif H5Eclear_vers == 1
#define H5Eclear H5Eclear1
@@ -96,6 +99,9 @@
#endif /* H5Eclear_vers */
#if !defined(H5Eget_auto_vers) || H5Eget_auto_vers == 2
+#ifndef H5Eget_auto_vers
+#define H5Eget_auto_vers 2
+#endif /* H5Eget_auto_vers */
#define H5Eget_auto H5Eget_auto2
#elif H5Eget_auto_vers == 1
#define H5Eget_auto H5Eget_auto1
@@ -104,6 +110,9 @@
#endif /* H5Eget_auto_vers */
#if !defined(H5Eprint_vers) || H5Eprint_vers == 2
+#ifndef H5Eprint_vers
+#define H5Eprint_vers 2
+#endif /* H5Eprint_vers */
#define H5Eprint H5Eprint2
#elif H5Eprint_vers == 1
#define H5Eprint H5Eprint1
@@ -112,6 +121,9 @@
#endif /* H5Eprint_vers */
#if !defined(H5Epush_vers) || H5Epush_vers == 2
+#ifndef H5Epush_vers
+#define H5Epush_vers 2
+#endif /* H5Epush_vers */
#define H5Epush H5Epush2
#elif H5Epush_vers == 1
#define H5Epush H5Epush1
@@ -120,6 +132,9 @@
#endif /* H5Epush_vers */
#if !defined(H5Eset_auto_vers) || H5Eset_auto_vers == 2
+#ifndef H5Eset_auto_vers
+#define H5Eset_auto_vers 2
+#endif /* H5Eset_auto_vers */
#define H5Eset_auto H5Eset_auto2
#elif H5Eset_auto_vers == 1
#define H5Eset_auto H5Eset_auto1
@@ -128,6 +143,9 @@
#endif /* H5Eset_auto_vers */
#if !defined(H5Ewalk_vers) || H5Ewalk_vers == 2
+#ifndef H5Ewalk_vers
+#define H5Ewalk_vers 2
+#endif /* H5Ewalk_vers */
#define H5Ewalk H5Ewalk2
#define H5E_error_t H5E_error2_t
#define H5E_walk_t H5E_walk2_t
@@ -140,6 +158,9 @@
#endif /* H5Ewalk_vers */
#if !defined(H5Gcreate_vers) || H5Gcreate_vers == 2
+#ifndef H5Gcreate_vers
+#define H5Gcreate_vers 2
+#endif /* H5Gcreate_vers */
#define H5Gcreate H5Gcreate2
#elif H5Gcreate_vers == 1
#define H5Gcreate H5Gcreate1
@@ -152,6 +173,9 @@
/************/
#if !defined(H5E_auto_t_vers) || H5E_auto_t_vers == 2
+#ifndef H5E_auto_t_vers
+#define H5E_auto_t_vers 2
+#endif /* H5E_auto_t_vers */
#define H5E_auto_t H5E_auto2_t
#elif H5E_auto_t_vers == 1
#define H5E_auto_t H5E_auto1_t