Changeset d5429345951a3d7fc02138f6eb8a121c4c5740d7

Show
Ignore:
Timestamp:
05/27/10 17:32:39 (4 years ago)
Author:
Theo Schlossnagle <jesus@omniti.com>
git-committer:
Theo Schlossnagle <jesus@omniti.com> 1274981559 +0000
git-parent:

[f8f8b5ec44b800ac487b2c5a90d2ac14f5eac4c0]

git-author:
Theo Schlossnagle <jesus@omniti.com> 1274981559 +0000
Message:

refs #284

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • src/noit_http.c

    rc6a5f68 rd542934  
    660660        /* We'd block to read more, but we have data, 
    661661         * so do a short read */ 
    662         if(ctx->req.first_input->size) break; 
     662        if(ctx->req.first_input && ctx->req.first_input->size) break; 
    663663        /* We've got nothing... */ 
    664664        noitL(http_debug, " ... noit_http_session_req_consume = -1 (EAGAIN)\n"); 
  • src/utils/noit_skiplist.c

    rde0d4f3 rd542934  
    167167  } 
    168168  noit_skiplisti_find_compare(sl, data, iter, prev, next, sl->comparek); 
    169   return (*iter)?((*iter)->data):(*iter)
     169  return (iter && *iter)?((*iter)->data):NULL
    170170} 
    171171static int noit_skiplisti_find_compare(noit_skiplist *sl, 
     
    187187      m=m->next; /* m->next is the match */ 
    188188      while(m->down) m=m->down; /* proceed to the bottom-most */ 
    189       *ret = m; 
     189      if(ret) *ret = m; 
    190190      if(prev) *prev = m->prev; 
    191191      if(next) *next = m->next; 
     
    204204      m = m->next, count++; 
    205205  } 
    206   *ret = NULL; 
     206  if(ret) *ret = NULL; 
    207207  return count; 
    208208} 
     
    290290    /* this is a external insertion, we must insert into each index as well */ 
    291291    noit_skiplist_node *p, *ni, *li; 
     292    assert(ret); 
    292293    li=ret; 
    293294    for(p = noit_skiplist_getlist(sl->index); p; noit_skiplist_next(sl->index, &p)) {