Commit:    b35ffdeae10eb1b71470eb831c02b3b7b838945d
Author:    Pierrick Charron <pierr...@php.net>         Wed, 26 Dec 2012 
10:13:56 -0500
Parents:   fad960a4045da86cdbd8308a165ffc47892f05b9
Branches:  PHP-5.3 PHP-5.4 PHP-5.5 master

Link:       
http://git.php.net/?p=php-src.git;a=commitdiff;h=b35ffdeae10eb1b71470eb831c02b3b7b838945d

Log:
Revert "Remove a useless memory write in zend_llist_del_element"

This reverts commit fad960a4045da86cdbd8308a165ffc47892f05b9 as
required by Stas and Christopher

Changed paths:
  M  Zend/zend_llist.c


Diff:
diff --git a/Zend/zend_llist.c b/Zend/zend_llist.c
index 26baf4d..4656420 100644
--- a/Zend/zend_llist.c
+++ b/Zend/zend_llist.c
@@ -91,13 +91,15 @@ ZEND_API void zend_llist_prepend_element(zend_llist *l, 
void *element)
 ZEND_API void zend_llist_del_element(zend_llist *l, void *element, int 
(*compare)(void *element1, void *element2))
 {
        zend_llist_element *current=l->head;
+       zend_llist_element *next;
 
        while (current) {
+               next = current->next;
                if (compare(current->data, element)) {
                        DEL_LLIST_ELEMENT(current, l);
                        break;
                }
-               current = current->next;
+               current = next;
        }
 }


--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to