summaryrefslogtreecommitdiff
path: root/zend
diff options
context:
space:
mode:
Diffstat (limited to 'zend')
-rw-r--r--zend/callable.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/zend/callable.h b/zend/callable.h
index 67863a9..9958a2a 100644
--- a/zend/callable.h
+++ b/zend/callable.h
@@ -41,7 +41,7 @@ public:
if (it->required()) _required++;
// fill the arg info
- fill(&_argv[i], *it);
+ fill(&_argv[i++], *it);
}
}
@@ -143,8 +143,8 @@ protected:
void fill(zend_arg_info *info, const Argument &arg) const
{
// fill members
- info->name = arg.name().c_str();
- info->name_len = arg.name().size();
+ info->name = arg.name();
+ info->name_len = ::strlen(arg.name());
#if PHP_VERSION_ID >= 50400
@@ -176,8 +176,8 @@ protected:
#endif
// this parameter is a regular type
- info->class_name = arg.type() == Type::Object ? arg.classname().c_str() : nullptr;
- info->class_name_len = arg.type() == Type::Object ? arg.classname().size() : 0;
+ info->class_name = arg.type() == Type::Object ? arg.classname() : nullptr;
+ info->class_name_len = arg.type() == Type::Object && arg.classname() ? ::strlen(arg.classname()) : 0;
info->allow_null = arg.allowNull();
info->pass_by_reference = arg.byReference();
}