mirror of
https://github.com/php/php-src.git
synced 2024-09-21 09:57:23 +00:00
ext/{standard,json,random,...}: add missing includes
This commit is contained in:
parent
16203b53e1
commit
308fd311ea
@ -14,6 +14,9 @@
|
||||
*/
|
||||
|
||||
#include "collator_is_numeric.h"
|
||||
#include "zend_strtod.h"
|
||||
|
||||
#include <errno.h>
|
||||
|
||||
/* {{{ Taken from PHP6:zend_u_strtod() */
|
||||
static double collator_u_strtod(const UChar *nptr, UChar **endptr) /* {{{ */
|
||||
|
@ -28,6 +28,7 @@
|
||||
#include "php_json_encoder.h"
|
||||
#include <zend_exceptions.h>
|
||||
#include "zend_enum.h"
|
||||
#include "zend_strtod.h" // for ZEND_DOUBLE_MAX_LENGTH
|
||||
|
||||
static const char digits[] = "0123456789abcdef";
|
||||
|
||||
|
@ -18,6 +18,7 @@
|
||||
#include "php_json_scanner.h"
|
||||
#include "php_json_scanner_defs.h"
|
||||
#include "php_json_parser.h"
|
||||
#include "zend_strtod.h"
|
||||
#include "json_parser.tab.h"
|
||||
|
||||
#define YYCTYPE php_json_ctype
|
||||
|
@ -30,6 +30,7 @@
|
||||
|
||||
#include "mbfilter.h"
|
||||
#include "mbfilter_base64.h"
|
||||
#include "zend_multiply.h" // for zend_safe_address_guarded()
|
||||
|
||||
static size_t mb_base64_to_wchar(unsigned char **in, size_t *in_len, uint32_t *buf, size_t bufsize, unsigned int *state);
|
||||
static void mb_wchar_to_base64(uint32_t *in, size_t len, mb_convert_buf *buf, bool end);
|
||||
|
@ -20,6 +20,7 @@
|
||||
#include "main/php.h"
|
||||
#include <float.h>
|
||||
#include "main/snprintf.h"
|
||||
#include "zend_strtod.h"
|
||||
|
||||
#define MAX_CHAR_BUF_LEN 255
|
||||
|
||||
|
@ -30,6 +30,8 @@
|
||||
#include "mysqlnd_ext_plugin.h"
|
||||
#include "zend_smart_str.h"
|
||||
|
||||
#include <errno.h>
|
||||
#include <string.h> // for strerror()
|
||||
|
||||
extern MYSQLND_CHARSET *mysqlnd_charsets;
|
||||
|
||||
|
@ -23,6 +23,7 @@
|
||||
#include "mysqlnd_wireprotocol.h"
|
||||
#include "mysqlnd_statistics.h"
|
||||
#include "mysqlnd_debug.h"
|
||||
#include "zend_strtod.h"
|
||||
|
||||
#define BAIL_IF_NO_MORE_DATA \
|
||||
if (UNEXPECTED((size_t)(p - begin) > packet->header.size)) { \
|
||||
|
@ -35,6 +35,7 @@
|
||||
|
||||
#include "php_oci8.h"
|
||||
#include "php_oci8_int.h"
|
||||
#include "zend_strtod.h"
|
||||
|
||||
/* {{{ php_oci_collection_create()
|
||||
Create and return connection handle */
|
||||
|
@ -51,6 +51,10 @@
|
||||
#include <pthread.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_MPROTECT
|
||||
#include <errno.h>
|
||||
#endif
|
||||
|
||||
#ifdef ZTS
|
||||
int jit_globals_id;
|
||||
#else
|
||||
|
@ -42,6 +42,7 @@
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
#include <errno.h>
|
||||
#include <fcntl.h>
|
||||
|
||||
#if HAVE_UNISTD_H
|
||||
|
@ -36,6 +36,8 @@
|
||||
#include <openssl/bn.h>
|
||||
#include <openssl/dh.h>
|
||||
|
||||
#include <errno.h>
|
||||
|
||||
#ifdef PHP_WIN32
|
||||
#include "win32/winutil.h"
|
||||
#include "win32/time.h"
|
||||
|
@ -20,6 +20,7 @@
|
||||
#include "php_pcre.h"
|
||||
#include "ext/standard/info.h"
|
||||
#include "ext/standard/basic_functions.h"
|
||||
#include "zend_multiply.h" // for zend_safe_address_guarded()
|
||||
#include "zend_smart_str.h"
|
||||
#include "SAPI.h"
|
||||
|
||||
|
@ -34,6 +34,8 @@
|
||||
#include "zend_exceptions.h"
|
||||
#include "pgsql_driver_arginfo.h"
|
||||
|
||||
#include <errno.h>
|
||||
|
||||
static bool pgsql_handle_in_transaction(pdo_dbh_t *dbh);
|
||||
|
||||
static char * _pdo_pgsql_trim_message(const char *message, int persistent)
|
||||
|
@ -39,6 +39,7 @@
|
||||
#include "php_pgsql.h"
|
||||
#include "php_globals.h"
|
||||
#include "zend_exceptions.h"
|
||||
#include "zend_strtod.h"
|
||||
|
||||
#ifdef HAVE_PGSQL
|
||||
|
||||
|
@ -21,6 +21,8 @@
|
||||
#include "func_interceptors.h"
|
||||
#include "phar_object_arginfo.h"
|
||||
|
||||
#include <errno.h>
|
||||
|
||||
static zend_class_entry *phar_ce_archive;
|
||||
static zend_class_entry *phar_ce_data;
|
||||
static zend_class_entry *phar_ce_PharException;
|
||||
|
@ -24,6 +24,8 @@
|
||||
#include "php_random.h"
|
||||
#include <math.h>
|
||||
|
||||
#include <float.h> // for DBL_MAX
|
||||
|
||||
/* This file implements the γ-section algorithm as published in:
|
||||
*
|
||||
* Drawing Random Floating-Point Numbers from an Interval. Frédéric
|
||||
|
@ -41,6 +41,7 @@
|
||||
# include <process.h>
|
||||
#else
|
||||
# include <sys/time.h>
|
||||
# include <errno.h>
|
||||
#endif
|
||||
|
||||
#ifdef __linux__
|
||||
|
@ -27,6 +27,8 @@
|
||||
#include "Zend/zend_enum.h"
|
||||
#include "Zend/zend_exceptions.h"
|
||||
|
||||
#include <float.h> // for DBL_MANT_DIG
|
||||
|
||||
static inline void randomizer_common_init(php_random_randomizer *randomizer, zend_object *engine_object) {
|
||||
if (engine_object->ce->type == ZEND_INTERNAL_CLASS) {
|
||||
/* Internal classes always php_random_engine struct */
|
||||
|
@ -33,11 +33,13 @@
|
||||
#include "tsrm_win32.h"
|
||||
#endif
|
||||
|
||||
|
||||
#ifdef HAVE_SHMOP
|
||||
|
||||
#include "ext/standard/info.h"
|
||||
|
||||
#include <errno.h>
|
||||
#include <string.h> // for strerror()
|
||||
|
||||
/* {{{ shmop_module_entry */
|
||||
zend_module_entry shmop_module_entry = {
|
||||
STANDARD_MODULE_HEADER,
|
||||
|
@ -25,6 +25,8 @@
|
||||
#include "zend_strtod.h"
|
||||
#include "zend_interfaces.h"
|
||||
|
||||
#include <errno.h>
|
||||
|
||||
/* zval type decode */
|
||||
static zval *to_zval_double(zval* ret, encodeTypePtr type, xmlNodePtr data);
|
||||
static zval *to_zval_long(zval* ret, encodeTypePtr type, xmlNodePtr data);
|
||||
|
@ -24,6 +24,7 @@
|
||||
# include <stdint.h>
|
||||
#endif
|
||||
|
||||
#include <errno.h>
|
||||
#include <limits.h>
|
||||
#include <stdarg.h>
|
||||
#include <stddef.h>
|
||||
|
@ -39,6 +39,7 @@
|
||||
#include "sockaddr_conv.h"
|
||||
#include "main/php_network.h"
|
||||
|
||||
#include <errno.h>
|
||||
|
||||
enum source_op {
|
||||
JOIN_SOURCE,
|
||||
|
@ -28,6 +28,8 @@
|
||||
#include <TSRM/TSRM.h>
|
||||
#endif
|
||||
|
||||
#include <errno.h>
|
||||
|
||||
#define MAX_USER_BUFF_SIZE ((size_t)(100*1024*1024))
|
||||
#define DEFAULT_BUFF_SIZE 8192
|
||||
#define MAX_ARRAY_KEY_SIZE 128
|
||||
|
@ -5,6 +5,7 @@
|
||||
#ifdef PHP_WIN32
|
||||
#include "windows_common.h"
|
||||
#else
|
||||
#include <errno.h>
|
||||
#include <netdb.h>
|
||||
#include <arpa/inet.h>
|
||||
#endif
|
||||
|
@ -36,6 +36,9 @@
|
||||
#include "spl_directory_arginfo.h"
|
||||
#include "spl_exceptions.h"
|
||||
|
||||
#include <errno.h>
|
||||
#include <string.h> // for strerror()
|
||||
|
||||
#define SPL_HAS_FLAG(flags, test_flag) ((flags & test_flag) ? 1 : 0)
|
||||
|
||||
/* declare the class handlers */
|
||||
|
@ -40,6 +40,7 @@
|
||||
#include "zend_smart_str.h"
|
||||
#include "zend_bitset.h"
|
||||
#include "zend_exceptions.h"
|
||||
#include "zend_strtod.h"
|
||||
#include "ext/spl/spl_array.h"
|
||||
#include "ext/random/php_random.h"
|
||||
|
||||
|
@ -117,6 +117,10 @@ PHPAPI php_basic_globals basic_globals;
|
||||
#include "streamsfuncs.h"
|
||||
#include "basic_functions_arginfo.h"
|
||||
|
||||
#if defined(HAVE_NANOSLEEP) || !defined(PHP_WIN32)
|
||||
#include <errno.h>
|
||||
#endif
|
||||
|
||||
typedef struct _user_tick_function_entry {
|
||||
zend_fcall_info fci;
|
||||
zend_fcall_info_cache fci_cache;
|
||||
|
@ -57,6 +57,9 @@ extern void __res_ndestroy(res_state statp);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#include <errno.h>
|
||||
#include <string.h> // for strerror()
|
||||
|
||||
#ifndef MAXHOSTNAMELEN
|
||||
#define MAXHOSTNAMELEN 255
|
||||
#endif
|
||||
|
@ -46,6 +46,10 @@
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_NICE
|
||||
#include <errno.h>
|
||||
#endif
|
||||
|
||||
#include <limits.h>
|
||||
|
||||
#ifdef PHP_WIN32
|
||||
|
@ -19,6 +19,7 @@
|
||||
#include "ext/standard/head.h"
|
||||
#include "php_string.h"
|
||||
#include "zend_execute.h"
|
||||
#include "zend_strtod.h" // for zend_gcvt()
|
||||
#include <stdio.h>
|
||||
|
||||
#include <locale.h>
|
||||
|
@ -27,6 +27,10 @@
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_FTOK
|
||||
|
||||
#include <errno.h>
|
||||
#include <string.h> // for strerror()
|
||||
|
||||
/* {{{ Convert a pathname and a project identifier to a System V IPC key */
|
||||
PHP_FUNCTION(ftok)
|
||||
{
|
||||
|
@ -17,6 +17,7 @@
|
||||
|
||||
#include "php.h"
|
||||
#include "hrtime.h"
|
||||
#include "zend_strtod.h"
|
||||
|
||||
/* {{{ */
|
||||
/* This file reuses code parts from the cross-platform timer library
|
||||
|
@ -44,6 +44,8 @@
|
||||
|
||||
#ifdef PHP_WIN32
|
||||
# include "win32/sendmail.h"
|
||||
#else
|
||||
# include <errno.h>
|
||||
#endif
|
||||
|
||||
#define SKIP_LONG_HEADER_SEP(str, pos) \
|
||||
|
@ -23,6 +23,7 @@
|
||||
#include "zend_exceptions.h"
|
||||
#include "zend_portability.h"
|
||||
#include "zend_bitset.h"
|
||||
#include "zend_strtod.h"
|
||||
|
||||
#include <math.h>
|
||||
#include <float.h>
|
||||
|
@ -47,6 +47,9 @@
|
||||
# include <netdb.h>
|
||||
#endif
|
||||
|
||||
#include <errno.h>
|
||||
#include <string.h> // for strerror()
|
||||
|
||||
PHPAPI zend_string* php_inet_ntop(const struct sockaddr *addr) {
|
||||
socklen_t addrlen = sizeof(struct sockaddr_in);
|
||||
|
||||
|
@ -29,6 +29,9 @@
|
||||
#include "php_fopen_wrappers.h"
|
||||
#include "SAPI.h"
|
||||
|
||||
#include <errno.h>
|
||||
#include <string.h> // for strerror()
|
||||
|
||||
static ssize_t php_stream_output_write(php_stream *stream, const char *buf, size_t count) /* {{{ */
|
||||
{
|
||||
PHPWRITE(buf, count);
|
||||
|
@ -36,6 +36,9 @@
|
||||
#include <fcntl.h>
|
||||
#endif
|
||||
|
||||
#include <errno.h>
|
||||
#include <string.h> // for strerror()
|
||||
|
||||
/* This symbol is defined in ext/standard/config.m4.
|
||||
* Essentially, it is set if you HAVE_FORK || PHP_WIN32
|
||||
* Other platforms may modify that configure check and add suitable #ifdefs
|
||||
|
@ -40,6 +40,9 @@ typedef unsigned long long php_timeout_ull;
|
||||
typedef unsigned __int64 php_timeout_ull;
|
||||
#endif
|
||||
|
||||
#include <errno.h>
|
||||
#include <string.h> // for strerror()
|
||||
|
||||
#define GET_CTX_OPT(stream, wrapper, name, val) (PHP_STREAM_CONTEXT(stream) && NULL != (val = php_stream_context_get_option(PHP_STREAM_CONTEXT(stream), wrapper, name)))
|
||||
|
||||
static php_stream_context *decode_context_param(zval *contextresource);
|
||||
|
@ -28,6 +28,7 @@
|
||||
#include "php_incomplete_class.h"
|
||||
#include "zend_enum.h"
|
||||
#include "zend_exceptions.h"
|
||||
#include "zend_strtod.h" // for zend_gcvt()
|
||||
/* }}} */
|
||||
|
||||
struct php_serialize_data {
|
||||
|
@ -19,6 +19,7 @@
|
||||
#include "php_incomplete_class.h"
|
||||
#include "zend_portability.h"
|
||||
#include "zend_exceptions.h"
|
||||
#include "zend_strtod.h"
|
||||
|
||||
/* {{{ reference-handling for unserializer: var_* */
|
||||
#define VAR_ENTRIES_MAX 1018 /* 1024 - offsetof(php_unserialize_data, entries) / sizeof(void*) */
|
||||
|
@ -22,10 +22,13 @@
|
||||
#include "php_globals.h"
|
||||
#include "ext/standard/info.h"
|
||||
#include "php_sysvmsg.h"
|
||||
#include "sysvmsg_arginfo.h"
|
||||
#include "ext/standard/php_var.h"
|
||||
#include "zend_smart_str.h"
|
||||
|
||||
#include <errno.h>
|
||||
#include "sysvmsg_arginfo.h"
|
||||
|
||||
#include <string.h> // for strerror()
|
||||
#include <sys/types.h>
|
||||
#include <sys/ipc.h>
|
||||
#include <sys/msg.h>
|
||||
|
Loading…
Reference in New Issue
Block a user