cvs: /php4 php_reentrancy.h reentrancy.c
| From: | Sascha Schumann | Date: | Tue, 30 Nov 1999 20:46:39 +0000 |
| Subject: | cvs: /php4 php_reentrancy.h reentrancy.c | ||
| Groups: | php.version4 | ||
| Request: | Send a blank email to php-version4+get-7113@lists.php.net to get a copy of this message | ||
sas Tue Nov 30 15:46:39 1999 EDT
Modified files:
/php4 php_reentrancy.h reentrancy.c
Log:
Add PHPAPI for Windows.
Index: php4/php_reentrancy.h
diff -u php4/php_reentrancy.h:1.4 php4/php_reentrancy.h:1.5
--- php4/php_reentrancy.h:1.4 Sat Nov 27 12:11:20 1999
+++ php4/php_reentrancy.h Tue Nov 30 15:46:07 1999
@@ -36,38 +36,38 @@
#if !defined(HAVE_LOCALTIME_R) && defined(HAVE_LOCALTIME)
#define PHP_NEED_REENTRANCY 1
#define localtime_r php_localtime_r
-struct tm *localtime_r(const time_t *const timep, struct tm *p_tm);
+PHPAPI struct tm *localtime_r(const time_t *const timep, struct tm *p_tm);
#endif
#if !defined(HAVE_CTIME_R) && defined(HAVE_CTIME)
#define PHP_NEED_REENTRANCY 1
#define ctime_r php_ctime_r
-char *ctime_r(const time_t *clock, char *buf);
+PHPAPI char *ctime_r(const time_t *clock, char *buf);
#endif
#if !defined(HAVE_ASCTIME_R) && defined(HAVE_ASCTIME)
#define PHP_NEED_REENTRANCY 1
#define asctime_r php_asctime_r
-char *asctime_r(const struct tm *tm, char *buf);
+PHPAPI char *asctime_r(const struct tm *tm, char *buf);
#endif
#if !defined(HAVE_GMTIME_R) && defined(HAVE_GMTIME)
#define PHP_NEED_REENTRANCY 1
#define gmtime_r php_gmtime_r
-struct tm *gmtime_r(const time_t *const timep, struct tm *p_tm);
+PHPAPI struct tm *gmtime_r(const time_t *const timep, struct tm *p_tm);
#endif
#if !defined(HAVE_STRTOK_R)
#define strtok_r php_strtok_r
-char *strtok_r(char *s, const char *delim, char **last);
+PHPAPI char *strtok_r(char *s, const char *delim, char **last);
#endif
#if !defined(HAVE_RAND_R)
#define rand_r php_rand_r
-int rand_r(unsigned int *seed);
+PHPAPI int rand_r(unsigned int *seed);
#endif
#if !defined(ZTS)
Index: php4/reentrancy.c
diff -u php4/reentrancy.c:1.6 php4/reentrancy.c:1.7
--- php4/reentrancy.c:1.6 Fri Nov 26 14:27:08 1999
+++ php4/reentrancy.c Tue Nov 30 15:46:07 1999
@@ -47,7 +47,7 @@
#if !defined(HAVE_LOCALTIME_R) && defined(HAVE_LOCALTIME)
-struct tm *localtime_r(const time_t *const timep, struct tm *p_tm)
+PHPAPI struct tm *localtime_r(const time_t *const timep, struct tm *p_tm)
{
struct tm *tmp;
@@ -65,7 +65,7 @@
#if !defined(HAVE_CTIME_R) && defined(HAVE_CTIME)
-char *ctime_r(const time_t *clock, char *buf)
+PHPAPI char *ctime_r(const time_t *clock, char *buf)
{
char *tmp;
@@ -83,7 +83,7 @@
#if !defined(HAVE_ASCTIME_R) && defined(HAVE_ASCTIME)
-char *asctime_r(const struct tm *tm, char *buf)
+PHPAPI char *asctime_r(const struct tm *tm, char *buf)
{
char *tmp;
@@ -101,7 +101,7 @@
#if !defined(HAVE_GMTIME_R) && defined(HAVE_GMTIME)
-struct tm *gmtime_r(const time_t *const timep, struct tm *p_tm)
+PHPAPI struct tm *gmtime_r(const time_t *const timep, struct tm *p_tm)
{
struct tm *tmp;
@@ -186,7 +186,7 @@
}
-int
+PHPAPI int
rand_r(unsigned int *ctx)
{
u_long val = (u_long) *ctx;
@@ -243,9 +243,8 @@
*/
#include <stddef.h>
-#include <string.h>
-char *
+PHPAPI char *
strtok_r(char *s, const char *delim, char **last)
{
char *spanp;