php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Return to Bug #60809
Patch bug60809.phpt revision 2012-01-20 02:39 UTC by pierrick@php.net
Patch 60809.diff revision 2012-01-20 02:19 UTC by pierrick@php.net

Patch 60809.diff for *General Issues Bug #60809

Patch version 2012-01-20 02:19 UTC

Return to Bug #60809 | Download this patch
Patch Revisions:

Developer: pierrick@php.net

Index: Zend/zend_compile.c
===================================================================
--- Zend/zend_compile.c	(revision 322482)
+++ Zend/zend_compile.c	(working copy)
@@ -4141,6 +4141,7 @@
 	zend_bool parent_prop_is_private = 0;
 	zend_bool not_compatible;
 	zval* prop_value;
+	char *doc_comment;
   
   
 	/* In the following steps the properties are inserted into the property table
@@ -4236,9 +4237,15 @@
 			}
 			Z_ADDREF_P(prop_value);
 
+			if (property_info->doc_comment) {
+				doc_comment = estrndup(property_info->doc_comment, property_info->doc_comment_len);
+			} else {
+				doc_comment = NULL;
+			}
+
 			zend_declare_property_ex(ce, prop_name, prop_name_length, 
 									 prop_value, property_info->flags, 
-								     property_info->doc_comment, property_info->doc_comment_len TSRMLS_CC);
+								     doc_comment, property_info->doc_comment_len TSRMLS_CC);
 		}
 	}
 }
 
PHP Copyright © 2001-2014 The PHP Group
All rights reserved.
Last updated: Sun Apr 20 03:02:42 2014 UTC