Changeset 1570

Show
Ignore:
Timestamp:
06/18/08 09:34:20 (3 months ago)
Author:
alo
Message:

--

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • cherokee/trunk/ChangeLog

    r1569 r1570  
    112008-06-18  Alvaro Lopez Ortega  <alvaro@alobbs.com> 
     2 
     3        * cherokee/avl.c (cherokee_avl_get, cherokee_avl_add) 
     4        (cherokee_avl_del): Added sanity check. The key must not be empty. 
    25 
    36        * cherokee/Makefile.am (libcherokeeinclude_HEADERS), 
  • cherokee/trunk/cherokee/avl.c

    r1439 r1570  
    379379        cherokee_avl_node_t *n = NULL; 
    380380 
     381        if (unlikely (cherokee_buffer_is_empty(key))) 
     382                return ret_error; 
     383 
    381384        /* Create the new AVL node 
    382385         */ 
     
    401404        cherokee_avl_node_t *node     = avl->root; 
    402405        cint_t               idx      = 1; 
     406 
     407        if (unlikely (cherokee_buffer_is_empty(key))) 
     408                return ret_error; 
    403409         
    404410        if (avl->root == NULL) 
     
    562568        short                re; 
    563569        cherokee_avl_node_t *node; 
     570 
     571        if (unlikely (cherokee_buffer_is_empty(key))) 
     572                return ret_error; 
    564573         
    565574        node = avl->root;