From 3c208ff875ae9fa19d4c8c7a277a8ea53eb69a32 Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Thu, 7 Jul 2011 14:05:21 +0100 Subject: [PATCH] We need to use strlen on hash keys. --- twig.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/twig.c b/twig.c index e93e5f5..8b7b84b 100644 --- a/twig.c +++ b/twig.c @@ -657,7 +657,7 @@ PHP_FUNCTION(twig_template_get_attributes) zval *tmp_class, *tmp_properties, *tmp_item, *tmp_object_item = NULL; tmp_class = TWIG_GET_ARRAY_ELEMENT(tmp_self_cache, class_name, strlen(class_name)); - tmp_properties = TWIG_GET_ARRAY_ELEMENT(tmp_class, "properties", sizeof("properties")); + tmp_properties = TWIG_GET_ARRAY_ELEMENT(tmp_class, "properties", strlen("properties")); tmp_item = TWIG_GET_ARRAY_ELEMENT_ZVAL(tmp_properties, item); if (tmp_item) { -- 1.7.2.5