summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2006-03-17 19:54:40 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2006-03-17 19:54:40 (GMT)
commit3597bbd700866e5673262cf1a9c7bb2b13da5286 (patch)
treed490d755b6710bb5f0e4ceae05479ef7262879b3
parent11a590c02b4d53ed926e2e86406f739fa846decb (diff)
downloadhdf5-3597bbd700866e5673262cf1a9c7bb2b13da5286.zip
hdf5-3597bbd700866e5673262cf1a9c7bb2b13da5286.tar.gz
hdf5-3597bbd700866e5673262cf1a9c7bb2b13da5286.tar.bz2
[svn-r12114] Purpose:
Code cleanup Description: Re-alphabetize the POSIX routines (again). Also, add proper prototype to HDrand() definition. Platforms tested: FreeBSD 4.11 (sleipnir) Too minor to require h5committest
-rw-r--r--src/H5private.h18
1 files changed, 11 insertions, 7 deletions
diff --git a/src/H5private.h b/src/H5private.h
index 01b41db..a67a6aa 100644
--- a/src/H5private.h
+++ b/src/H5private.h
@@ -776,19 +776,13 @@ typedef off_t h5_stat_size_t;
#ifdef H5_HAVE_RAND_R
#define HDrandom() HDrand()
-#define HDsrandom(S) HDsrand(S)
-H5_DLL int HDrand();
-H5_DLL void HDsrand(unsigned int seed);
+H5_DLL int HDrand(void);
#elif H5_HAVE_RANDOM
#define HDrand() random()
#define HDrandom() random()
-#define HDsrandom(S) srandom(S)
-#define HDsrand(S) srandom(S)
#else
#define HDrand() rand()
#define HDrandom() rand()
-#define HDsrandom(S) srand(S)
-#define HDsrand(S) srand(S)
#endif
#define HDread(F,M,Z) read(F,M,Z)
@@ -834,6 +828,16 @@ H5_DLL void HDsrand(unsigned int seed);
#endif
/* sprintf() variable arguments */
#define HDsqrt(X) sqrt(X)
+#ifdef H5_HAVE_RAND_R
+H5_DLL void HDsrand(unsigned int seed);
+#define HDsrandom(S) HDsrand(S)
+#elif H5_HAVE_RANDOM
+#define HDsrand(S) srandom(S)
+#define HDsrandom(S) srandom(S)
+#else
+#define HDsrand(S) srand(S)
+#define HDsrandom(S) srand(S)
+#endif
/* sscanf() variable arguments */
#ifdef WIN32