Re: zend_hash_add_or_update flaw

From: Date: Wed, 06 Dec 2000 20:58:23 +0000
Subject: Re: zend_hash_add_or_update flaw
References: 1  Groups: php.dev 
Request: Send a blank email to php-dev+get-40254@lists.php.net to get a copy of this message
At 09:50 PM 12/6/00 +0100, Sascha Schumann wrote:
Right. It doesn't work with unaligned data but did you actually bump into such a case in PHP? I prefer not moving to memcpy() unless this is actually the case.
    Yes (please refer to my first message). We are basically
    strtok'ing through a string and adding parts of that string
    to the hash.
    memcpy is often implemented as an inline function or even
    assembler by the C library, so the speed impact should be
    negligible.
OK, I didn't realize you are actually being bitten by this. Go ahead and commit your patch. Andi --- Andi Gutmans <andi@zend.com> http://www.zend.com/

« previous php.dev (#40254) next »