summaryrefslogtreecommitdiff
path: root/ext/xmlwriter/php_xmlwriter.h
diff options
context:
space:
mode:
Diffstat (limited to 'ext/xmlwriter/php_xmlwriter.h')
-rw-r--r--ext/xmlwriter/php_xmlwriter.h12
1 files changed, 9 insertions, 3 deletions
diff --git a/ext/xmlwriter/php_xmlwriter.h b/ext/xmlwriter/php_xmlwriter.h
index e21a5e3510..fc00a9d578 100644
--- a/ext/xmlwriter/php_xmlwriter.h
+++ b/ext/xmlwriter/php_xmlwriter.h
@@ -1,8 +1,8 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
- | Copyright (c) 1997-2013 The PHP Group |
+ | Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
@@ -45,10 +45,16 @@ typedef struct _xmlwriter_object {
/* Extends zend object */
typedef struct _ze_xmlwriter_object {
- zend_object zo;
xmlwriter_object *xmlwriter_ptr;
+ zend_object std;
} ze_xmlwriter_object;
+static inline ze_xmlwriter_object *php_xmlwriter_fetch_object(zend_object *obj) {
+ return (ze_xmlwriter_object *)((char*)(obj) - XtOffsetOf(ze_xmlwriter_object, std));
+}
+
+#define Z_XMLWRITER_P(zv) php_xmlwriter_fetch_object(Z_OBJ_P((zv)))
+
#endif /* PHP_XMLWRITER_H */
/*