Branch: Tag:

1999-08-20

1999-08-20 20:04:31 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Fixed a few memory leaks.

Rev: src/modules/Gz/zlibmod.c:1.27

3:   ||| Pike is distributed as GPL (General Public License)   ||| See the files COPYING and DISCLAIMER for more information.   \*/ + /**/   #include "global.h" - RCSID("$Id: zlibmod.c,v 1.26 1999/07/15 16:58:44 hubbe Exp $"); + RCSID("$Id: zlibmod.c,v 1.27 1999/08/20 20:04:31 grubba Exp $");      #include "zlib_machine.h"   
135:    if(!THIS->gz.state)    error("gz_deflate not initialized or destructed\n");    -  initialize_buf(&buf); -  +     if(args<1)    error("Too few arguments to gz_deflate->deflate()\n");   
170:    this->gz.next_in=(Bytef *)data->str;    this->gz.avail_in=data->len;    +  initialize_buf(&buf); +     fail=do_deflate(&buf,this,flush);    pop_n_elems(args);   
287:    if(!THIS->gz.state)    error("gz_inflate not initialized or destructed\n");    -  initialize_buf(&buf); -  +     if(args<1)    error("Too few arguments to gz_inflate->inflate()\n");   
300:    this->gz.next_in=(Bytef *)data->str;    this->gz.avail_in=data->len;    +  initialize_buf(&buf); +     fail=do_inflate(&buf,this,Z_PARTIAL_FLUSH);    pop_n_elems(args);