Skip to content
Snippets Groups Projects
Commit 04e303cb authored by Martin Nilsson's avatar Martin Nilsson
Browse files

Documentation is always good, even when it says we have no clue how things...

Documentation is always good, even when it says we have no clue how things works. Always clear the stack, not only when it is empty.

Rev: src/modules/Gz/zlibmod.c:1.61
parent 8ecc0efb
Branches
Tags
No related merge requests found
...@@ -2,11 +2,11 @@ ...@@ -2,11 +2,11 @@
|| This file is part of Pike. For copyright information see COPYRIGHT. || This file is part of Pike. For copyright information see COPYRIGHT.
|| Pike is distributed under GPL, LGPL and MPL. See the file COPYING || Pike is distributed under GPL, LGPL and MPL. See the file COPYING
|| for more information. || for more information.
|| $Id: zlibmod.c,v 1.60 2003/03/30 19:02:39 per Exp $ || $Id: zlibmod.c,v 1.61 2003/03/30 20:45:35 nilsson Exp $
*/ */
#include "global.h" #include "global.h"
RCSID("$Id: zlibmod.c,v 1.60 2003/03/30 19:02:39 per Exp $"); RCSID("$Id: zlibmod.c,v 1.61 2003/03/30 20:45:35 nilsson Exp $");
#include "zlib_machine.h" #include "zlib_machine.h"
#include "module.h" #include "module.h"
...@@ -313,6 +313,12 @@ static void exit_gz_deflate(struct object *o) ...@@ -313,6 +313,12 @@ static void exit_gz_deflate(struct object *o)
*/ */
/*! @decl void create(int|void magic) /*! @decl void create(int|void magic)
*! @param magic
*! The magic value is passed down to inflateInit2 in zlib. Specifically,
*! if you want to uncompress PKZIP-compressed data, you have to specify
*! -15 as the argument. What negative arguments does is undocumented as
*! far as we know. Positive arguments set the maximum dictionary size
*! though.
*/ */
static void gz_inflate_create(INT32 args) static void gz_inflate_create(INT32 args)
{ {
...@@ -334,9 +340,10 @@ static void gz_inflate_create(INT32 args) ...@@ -334,9 +340,10 @@ static void gz_inflate_create(INT32 args)
} }
else else
{ {
pop_n_elems(args);
tmp=inflateInit( &THIS->gz ); tmp=inflateInit( &THIS->gz );
} }
pop_n_elems(args);
/* mt_lock(& THIS->lock); */ /* mt_lock(& THIS->lock); */
/* mt_unlock(& THIS->lock); */ /* mt_unlock(& THIS->lock); */
switch(tmp) switch(tmp)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment