OSDN Git Service

5.4 => zend_list_insert(swf, le_swfed TSRMLS_CC);
authorよや <yoya@awm.jp>
Thu, 16 Feb 2012 11:48:36 +0000 (20:48 +0900)
committerよや <yoya@awm.jp>
Thu, 16 Feb 2012 11:48:36 +0000 (20:48 +0900)
5.3 and before => zend_list_insert(swf, le_swfed)

src/php_swfed.c

index ce5e7c4..2e26ce3 100644 (file)
@@ -284,7 +284,11 @@ PHP_METHOD(swfed, __construct) {
     if (swf == NULL) {
         php_error_docref(NULL TSRMLS_CC, E_ERROR, "Couldn't create swf object");
     }
+#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION > 3) || (PHP_MAJOR_VERSION > 5)
     ret = zend_list_insert(swf, le_swfed TSRMLS_CC);
+#else
+    ret = zend_list_insert(swf, le_swfed);
+#endif
     object_init_ex(getThis(), swfeditor_ce);
     add_property_resource(getThis(), "swfed", ret);
     zend_list_addref(ret);