Branch: Tag:

2008-06-23

2008-06-23 16:05:02 by Martin Stjernholm <mast@lysator.liu.se>

Adaptions to new SearchMojt behavior. Fixed some possible leaks on (at
least) out-of-memory errors.

Rev: src/array.c:1.210
Rev: src/stralloc.c:1.221

2:   || This file is part of Pike. For copyright information see COPYRIGHT.   || Pike is distributed under GPL, LGPL and MPL. See the file COPYING   || for more information. - || $Id: array.c,v 1.209 2008/05/30 15:19:02 mast Exp $ + || $Id: array.c,v 1.210 2008/06/23 16:05:02 mast Exp $   */      #include "global.h"
2285:    }    }else{    SearchMojt mojt; +  ONERROR uwp;    explode_searchfunc f = (explode_searchfunc)0;       s=str->str;
2297:    del->len,    str->len,    del); +  SET_ONERROR (uwp, do_free_object, mojt.container);       switch(str->size_shift)    {
2343:       ITEM(ret)[ret->size].type=T_STRING;    ret->size++; -  mojt.vtab->freeme(mojt.data); +  +  CALL_AND_UNSET_ONERROR (uwp);    }    ret->type_field=BIT_STRING;    return ret;