Branch: Tag:

2008-06-29

2008-06-29 17:56:06 by Martin Nilsson <mani@lysator.liu.se>

Clear strings if clear on exit bit is set.

Rev: src/stralloc.c:1.224
Rev: src/stralloc.h:1.108

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: stralloc.c,v 1.223 2008/06/23 19:22:52 mast Exp $ + || $Id: stralloc.c,v 1.224 2008/06/29 17:56:06 nilsson Exp $   */      #include "global.h"
1092:   #endif    if (!(s->flags & STRING_NOT_SHARED))    unlink_pike_string(s); +  if (s->flags & STRING_CLEAR_ON_EXIT) +  MEMSET(s->str, 0, s->len);    free_unlinked_pike_string(s);    GC_FREE_SIMPLE_BLOCK(s);   }