forked from Jille/php-sigsock
-
Notifications
You must be signed in to change notification settings - Fork 0
/
php_sigsock.h
85 lines (66 loc) · 1.64 KB
/
php_sigsock.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
/*
+----------------------------------------------------------------------+
| unknown license: |
+----------------------------------------------------------------------+
+----------------------------------------------------------------------+
*/
/* $ Id: $ */
#ifndef PHP_SIGSOCK_H
#define PHP_SIGSOCK_H
#ifdef __cplusplus
extern "C" {
#endif
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include <php.h>
#ifdef HAVE_SIGSOCK
#define PHP_SIGSOCK_VERSION "0.1.0"
#define SIGSOCK_MAX_SIGNALS 32
#include <php_ini.h>
#include <SAPI.h>
#include <ext/standard/info.h>
#include <Zend/zend_extensions.h>
#ifdef __cplusplus
} // extern "C"
#endif
#ifdef __cplusplus
extern "C" {
#endif
extern zend_module_entry sigsock_module_entry;
#define phpext_sigsock_ptr &sigsock_module_entry
#ifdef PHP_WIN32
#define PHP_SIGSOCK_API __declspec(dllexport)
#else
#define PHP_SIGSOCK_API
#endif
PHP_MINIT_FUNCTION(sigsock);
PHP_MSHUTDOWN_FUNCTION(sigsock);
PHP_RINIT_FUNCTION(sigsock);
PHP_RSHUTDOWN_FUNCTION(sigsock);
PHP_MINFO_FUNCTION(sigsock);
ZEND_BEGIN_MODULE_GLOBALS(sigsock)
int socktable[SIGSOCK_MAX_SIGNALS+1];
zval *streamtable[SIGSOCK_MAX_SIGNALS+1];
ZEND_END_MODULE_GLOBALS(sigsock)
#ifdef ZTS
#define SIGSOCK_G(v) TSRMG(sigsock_globals_id, zend_sigsock_globals *, v)
#else
#define SIGSOCK_G(v) (sigsock_globals.v)
#endif
#ifdef ZTS
#include "TSRM.h"
#endif
#ifdef __cplusplus
} // extern "C"
#endif
#endif /* PHP_HAVE_SIGSOCK */
#endif /* PHP_SIGSOCK_H */
/*
* Local variables:
* tab-width: 4
* c-basic-offset: 4
* End:
* vim600: noet sw=4 ts=4 fdm=marker
* vim<600: noet sw=4 ts=4
*/