From c3e3c98ec666812daaaca896cf5ef758a8a6df14 Mon Sep 17 00:00:00 2001 From: Anatol Belski Date: Mon, 25 Aug 2014 19:24:55 +0200 Subject: master renames phase 1 --- main/php.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'main/php.h') diff --git a/main/php.h b/main/php.h index a271f0d5fc..fc105386db 100644 --- a/main/php.h +++ b/main/php.h @@ -66,9 +66,9 @@ # define PHP_EOL "\n" #endif -#define php_size_t zend_size_t -#define php_int_t zend_int_t -#define php_uint_t zend_uint_t +#define php_size_t size_t +#define zend_long zend_long +#define zend_ulong zend_ulong #define php_off_t zend_off_t #define PHP_INT_MAX ZEND_INT_MAX #define PHP_INT_MIN ZEND_INT_MIN -- cgit v1.2.1 From 4d997f63d98c663b2d9acccd3655572652f61c7d Mon Sep 17 00:00:00 2001 From: Anatol Belski Date: Mon, 25 Aug 2014 20:22:49 +0200 Subject: master renames phase 3 --- main/php.h | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) (limited to 'main/php.h') diff --git a/main/php.h b/main/php.h index fc105386db..8ee83e424d 100644 --- a/main/php.h +++ b/main/php.h @@ -66,15 +66,6 @@ # define PHP_EOL "\n" #endif -#define php_size_t size_t -#define zend_long zend_long -#define zend_ulong zend_ulong -#define php_off_t zend_off_t -#define PHP_INT_MAX ZEND_INT_MAX -#define PHP_INT_MIN ZEND_INT_MIN -#define PHP_UINT_MAX ZEND_UINT_MAX -#define PHP_SIZE_MAX ZEND_SIZE_MAX - #ifdef NETWARE /* For php_get_uname() function */ #define PHP_UNAME "NetWare" @@ -289,8 +280,8 @@ ssize_t pread(int, void *, size_t, off64_t); BEGIN_EXTERN_C() void phperror(char *error); -PHPAPI php_size_t php_write(void *buf, php_size_t size TSRMLS_DC); -PHPAPI php_size_t php_printf(const char *format, ...) PHP_ATTRIBUTE_FORMAT(printf, 1, +PHPAPI size_t php_write(void *buf, size_t size TSRMLS_DC); +PHPAPI size_t php_printf(const char *format, ...) PHP_ATTRIBUTE_FORMAT(printf, 1, 2); PHPAPI int php_get_module_initialized(void); PHPAPI void php_log_err(char *log_message TSRMLS_DC); -- cgit v1.2.1 From 202e8db1dc8e1203039327d81ce6fd82c1c2d909 Mon Sep 17 00:00:00 2001 From: Anatol Belski Date: Tue, 26 Aug 2014 11:23:25 +0200 Subject: fixed several long vs zend_long casts --- main/php.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'main/php.h') diff --git a/main/php.h b/main/php.h index 8ee83e424d..11a8a64401 100644 --- a/main/php.h +++ b/main/php.h @@ -434,7 +434,7 @@ END_EXTERN_C() #else /* ! (CRAY || __arm) */ #define XtOffset(p_type, field) \ - ((long) (((char *) (&(((p_type)NULL)->field))) - ((char *) NULL))) + ((zend_long) (((char *) (&(((p_type)NULL)->field))) - ((char *) NULL))) #endif /* !CRAY */ #endif /* ! XtOffset */ -- cgit v1.2.1 From 25f5ba94aca1e89ee5f0c66513e58826afa3b853 Mon Sep 17 00:00:00 2001 From: Nuno Lopes Date: Sun, 31 Aug 2014 11:45:11 -0400 Subject: remove a few gcc format attributes from some printf-like functions Since now PHP's printf-like functions have many custom specifiers, the amount of false-positives wasnt worth it --- main/php.h | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) (limited to 'main/php.h') diff --git a/main/php.h b/main/php.h index 11a8a64401..47e1e10733 100644 --- a/main/php.h +++ b/main/php.h @@ -281,12 +281,9 @@ ssize_t pread(int, void *, size_t, off64_t); BEGIN_EXTERN_C() void phperror(char *error); PHPAPI size_t php_write(void *buf, size_t size TSRMLS_DC); -PHPAPI size_t php_printf(const char *format, ...) PHP_ATTRIBUTE_FORMAT(printf, 1, - 2); +PHPAPI size_t php_printf(const char *format, ...); PHPAPI int php_get_module_initialized(void); PHPAPI void php_log_err(char *log_message TSRMLS_DC); -int Debug(char *format, ...) PHP_ATTRIBUTE_FORMAT(printf, 1, 2); -int cfgparse(void); END_EXTERN_C() #define php_error zend_error @@ -308,12 +305,9 @@ PHPAPI void php_verror(const char *docref, const char *params, int type, const c #endif /* PHPAPI void php_error(int type, const char *format, ...); */ -PHPAPI void php_error_docref0(const char *docref TSRMLS_DC, int type, const char *format, ...) - PHP_ATTRIBUTE_FORMAT(printf, PHP_ATTR_FMT_OFFSET + 3, PHP_ATTR_FMT_OFFSET + 4); -PHPAPI void php_error_docref1(const char *docref TSRMLS_DC, const char *param1, int type, const char *format, ...) - PHP_ATTRIBUTE_FORMAT(printf, PHP_ATTR_FMT_OFFSET + 4, PHP_ATTR_FMT_OFFSET + 5); -PHPAPI void php_error_docref2(const char *docref TSRMLS_DC, const char *param1, const char *param2, int type, const char *format, ...) - PHP_ATTRIBUTE_FORMAT(printf, PHP_ATTR_FMT_OFFSET + 5, PHP_ATTR_FMT_OFFSET + 6); +PHPAPI void php_error_docref0(const char *docref TSRMLS_DC, int type, const char *format, ...); +PHPAPI void php_error_docref1(const char *docref TSRMLS_DC, const char *param1, int type, const char *format, ...); +PHPAPI void php_error_docref2(const char *docref TSRMLS_DC, const char *param1, const char *param2, int type, const char *format, ...); #ifdef PHP_WIN32 PHPAPI void php_win32_docref2_from_error(DWORD error, const char *param1, const char *param2 TSRMLS_DC); #endif -- cgit v1.2.1 From fdd1e96f3e90895134c4082bde8cad475378deac Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Wed, 3 Sep 2014 15:22:08 +0200 Subject: Revert "remove a few gcc format attributes from some printf-like functions" This reverts commit 25f5ba94aca1e89ee5f0c66513e58826afa3b853. --- main/php.h | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) (limited to 'main/php.h') diff --git a/main/php.h b/main/php.h index 47e1e10733..11a8a64401 100644 --- a/main/php.h +++ b/main/php.h @@ -281,9 +281,12 @@ ssize_t pread(int, void *, size_t, off64_t); BEGIN_EXTERN_C() void phperror(char *error); PHPAPI size_t php_write(void *buf, size_t size TSRMLS_DC); -PHPAPI size_t php_printf(const char *format, ...); +PHPAPI size_t php_printf(const char *format, ...) PHP_ATTRIBUTE_FORMAT(printf, 1, + 2); PHPAPI int php_get_module_initialized(void); PHPAPI void php_log_err(char *log_message TSRMLS_DC); +int Debug(char *format, ...) PHP_ATTRIBUTE_FORMAT(printf, 1, 2); +int cfgparse(void); END_EXTERN_C() #define php_error zend_error @@ -305,9 +308,12 @@ PHPAPI void php_verror(const char *docref, const char *params, int type, const c #endif /* PHPAPI void php_error(int type, const char *format, ...); */ -PHPAPI void php_error_docref0(const char *docref TSRMLS_DC, int type, const char *format, ...); -PHPAPI void php_error_docref1(const char *docref TSRMLS_DC, const char *param1, int type, const char *format, ...); -PHPAPI void php_error_docref2(const char *docref TSRMLS_DC, const char *param1, const char *param2, int type, const char *format, ...); +PHPAPI void php_error_docref0(const char *docref TSRMLS_DC, int type, const char *format, ...) + PHP_ATTRIBUTE_FORMAT(printf, PHP_ATTR_FMT_OFFSET + 3, PHP_ATTR_FMT_OFFSET + 4); +PHPAPI void php_error_docref1(const char *docref TSRMLS_DC, const char *param1, int type, const char *format, ...) + PHP_ATTRIBUTE_FORMAT(printf, PHP_ATTR_FMT_OFFSET + 4, PHP_ATTR_FMT_OFFSET + 5); +PHPAPI void php_error_docref2(const char *docref TSRMLS_DC, const char *param1, const char *param2, int type, const char *format, ...) + PHP_ATTRIBUTE_FORMAT(printf, PHP_ATTR_FMT_OFFSET + 5, PHP_ATTR_FMT_OFFSET + 6); #ifdef PHP_WIN32 PHPAPI void php_win32_docref2_from_error(DWORD error, const char *param1, const char *param2 TSRMLS_DC); #endif -- cgit v1.2.1 From d0cb715373c3fbe9dc095378ec5ed8c71f799f67 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Schl=C3=BCter?= Date: Fri, 19 Sep 2014 18:33:14 +0200 Subject: s/PHP 5/PHP 7/ --- main/php.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'main/php.h') diff --git a/main/php.h b/main/php.h index 11a8a64401..2a683e1924 100644 --- a/main/php.h +++ b/main/php.h @@ -1,6 +1,6 @@ /* +----------------------------------------------------------------------+ - | PHP Version 5 | + | PHP Version 7 | +----------------------------------------------------------------------+ | Copyright (c) 1997-2014 The PHP Group | +----------------------------------------------------------------------+ -- cgit v1.2.1