1
1
/*
2
- +----------------------------------------------------------------------+
3
- | XZ Extension |
4
- +----------------------------------------------------------------------+
5
- | Copyright (c) 1997-2015 The PHP Group |
6
- +----------------------------------------------------------------------+
7
- | This source file is subject to version 3.01 of the PHP license, |
8
- | that is bundled with this package in the file LICENSE, and is |
9
- | available through the world-wide-web at the following url: |
10
- | http://www.php.net/license/3_01.txt |
11
- | If you did not receive a copy of the PHP license and are unable to |
12
- | obtain it through the world-wide-web, please send a note to |
13
- | license@php.net so we can mail you a copy immediately. |
14
- +----------------------------------------------------------------------+
15
- | Authors: Payden Sutherland <payden@paydensutherland.com> |
16
- | Dan Ungureanu <udan1107@gmail.com> |
17
- | authors of the `zlib` extension (for guidance) |
18
- +----------------------------------------------------------------------+
2
+ +----------------------------------------------------------------------+
3
+ | PHP Version 5 |
4
+ +----------------------------------------------------------------------+
5
+ | Copyright (c) 1997-2015 The PHP Group |
6
+ +----------------------------------------------------------------------+
7
+ | This source file is subject to version 3.01 of the PHP license, |
8
+ | that is bundled with this package in the file LICENSE, and is |
9
+ | available through the world-wide-web at the following url: |
10
+ | http://www.php.net/license/3_01.txt |
11
+ | If you did not receive a copy of the PHP license and are unable to |
12
+ | obtain it through the world-wide-web, please send a note to |
13
+ | license@php.net so we can mail you a copy immediately. |
14
+ +----------------------------------------------------------------------+
15
+ | Authors: Payden Sutherland <payden@paydensutherland.com> |
16
+ | Dan Ungureanu <udan1107@gmail.com> |
17
+ | authors of the `zlib` extension (for guidance) |
18
+ +----------------------------------------------------------------------+
19
19
*/
20
20
21
21
#ifndef PHP_XZ_H
@@ -26,72 +26,47 @@ extern php_stream_wrapper php_stream_xz_wrapper;
26
26
27
27
#define phpext_xz_ptr &xz_module_entry
28
28
29
- /**
30
- * The default size of the buffer used for compression and decompression.
31
- */
29
+ /* The default size of the buffer used for compression and decompression. */
32
30
#define XZ_BUFFER_SIZE 4096
33
31
34
32
#ifdef PHP_WIN32
35
- # define PHP_XZ_API __declspec(dllexport)
33
+ # define PHP_XZ_API __declspec(dllexport)
36
34
#elif defined(__GNUC__ ) && (__GNUC__ >= 4 )
37
- # define PHP_XZ_API __attribute__ ((visibility("default")))
35
+ # define PHP_XZ_API __attribute__ ((visibility("default")))
38
36
#else
39
- # define PHP_XZ_API
37
+ # define PHP_XZ_API
40
38
#endif
41
39
42
40
#ifdef ZTS
43
- # include "TSRM.h"
41
+ # include "TSRM.h"
44
42
#endif
45
43
46
- /**
47
- * Function called when module initializes.
48
- */
49
44
PHP_MINIT_FUNCTION (xz );
50
-
51
- /**
52
- * Function called when module shuts down.
53
- */
54
45
PHP_MSHUTDOWN_FUNCTION (xz );
55
46
56
- /**
57
- * Function called to retrieve module's information.
58
- */
59
47
PHP_MINFO_FUNCTION (xz );
60
48
61
- /**
62
- * Opens a XZ stream.
63
- */
64
49
PHP_FUNCTION (xzopen );
65
-
66
- /**
67
- * Encodes a given string.
68
- */
69
50
PHP_FUNCTION (xzencode );
70
-
71
- /**
72
- * Decodes a given string.
73
- */
74
51
PHP_FUNCTION (xzdecode );
75
52
76
- /**
77
- * Function that opens a stream. It is internally used for `xzopen`.
78
- *
79
- * @param wrapper
80
- * @param path
81
- * @param mode_pass
82
- * @param options
83
- * @param opened_path
84
- *
85
- * @return
86
- */
87
53
php_stream * php_stream_xzopen (php_stream_wrapper * wrapper , const char * path ,
88
- const char * mode_pass , int options , char * * opened_path ,
89
- php_stream_context * context STREAMS_DC TSRMLS_DC );
54
+ const char * mode_pass , int options , char * * opened_path ,
55
+ php_stream_context * context STREAMS_DC TSRMLS_DC );
90
56
91
57
#ifdef ZTS
92
- # define XZ_G (v ) TSRMG(xz_globals_id, zend_xz_globals *, v)
58
+ # define XZ_G (v ) TSRMG(xz_globals_id, zend_xz_globals *, v)
93
59
#else
94
- # define XZ_G (v ) (xz_globals.v)
60
+ # define XZ_G (v ) (xz_globals.v)
95
61
#endif
96
62
97
63
#endif
64
+
65
+ /*
66
+ * Local variables:
67
+ * tab-width: 4
68
+ * c-basic-offset: 4
69
+ * End:
70
+ * vim600: sw=4 ts=4 fdm=marker
71
+ * vim<600: sw=4 ts=4
72
+ */
0 commit comments