From 34e4fd0b5aae872344a16267efac847f45108ca7 Mon Sep 17 00:00:00 2001 From: Frederic Peters Date: Tue, 29 Apr 2008 12:06:25 +0000 Subject: [project @ fpeters@0d.be-20080118215410-d45drghkhvba7822] merged Damien branch; and fixed PHP5 binding to use GLib memory management functions Original author: Frederic Peters Date: 2008-01-18 22:54:10.239000+01:00 --- bindings/lang_php5_helpers/wrapper_source.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'bindings/lang_php5_helpers/wrapper_source.py') diff --git a/bindings/lang_php5_helpers/wrapper_source.py b/bindings/lang_php5_helpers/wrapper_source.py index 1dfef51a..c6a348a9 100644 --- a/bindings/lang_php5_helpers/wrapper_source.py +++ b/bindings/lang_php5_helpers/wrapper_source.py @@ -343,13 +343,13 @@ PHP_MSHUTDOWN_FUNCTION(lasso) print >> self.fd, ' this->%s = %s;' % (m_name, m_name) elif parse_tuple_format == 's': print >> self.fd, ' if (this->%s) {' % m_name - print >> self.fd, ' efree(this->%s);' % m_name + print >> self.fd, ' g_free(this->%s);' % m_name print >> self.fd, ' }' print >> self.fd, ' if (%s_str && strcmp(%s_str, "") != 0) {' % (m_name, m_name) if arg_type == 'xmlNode*': print >> self.fd, ' this->%s = get_xml_node_from_string(%s_str);' % (m_name, m_name) else: - print >> self.fd, ' this->%s = estrndup(%s_str, %s_len);' % (m_name, m_name, m_name) + print >> self.fd, ' this->%s = g_strndup(%s_str, %s_len);' % (m_name, m_name, m_name) print >> self.fd, ' } else {' print >> self.fd, ' this->%s = NULL;' % m_name print >> self.fd, ' }' -- cgit