Re: [PHP-DEV] Newbie question: zend_hash_find

2006-11-08 Thread Matt Wilmas
Hi Arnold, zend_hash_find() is always returning FAILURE because its "key_length" parameter *includes* the terminating '\0'. :-) So you need strlen(key) + 1. BTW, are any of your keys going to have numeric values ([123] sections etc.)? Then you'll also have a problem with hash_find() as it doesn

[PHP-DEV] Newbie question: zend_hash_find

2006-11-08 Thread Arnold Daniels
Hi, I'm new at PHP internals and have read the 'Extension Writing' tutorial (part 1-3) of devzone.zend.com. I'm writing a set of parsers, to parse different kind of configuration formats. The first is an .ini parser. The code almost works correctly. The only problem I have is that sections ge