pike.git/src/modules/Gz/zlibmod.c:1068:
crc=0;
crc=crc32(crc,
(unsigned char*)sp[-args].u.string->str,
DO_NOT_WARN((unsigned INT32)(sp[-args].u.string->len)));
pop_n_elems(args);
push_int((INT32)crc);
}
- /*! @endmodule
- */
- #endif
-
- PIKE_MODULE_EXIT {}
-
+
static void gz_deflate_size( INT32 args )
{
#define L_CODES (256 + 29 + 1)
#define HEAP_SIZE (2*L_CODES+1)
pop_n_elems(args);
/* estimation, from reading deflate.h. We could get a rather exact
* value if we saved memlevel + windowbits somewhere.
*/
push_int(
pike.git/src/modules/Gz/zlibmod.c:1104:
/* low-order estimation, from reading inflate.h */
push_int(
/* inflate_state structure. */
((28 * sizeof(void*)) + (320 * 2) + (288 * 2)) +
/* codes[] */
(2048 * 4) +
/* window, really 1<<wbits, max wbits is 16. */
65536);
}
+ /*! @endmodule
+ */
+ #endif
+
PIKE_MODULE_INIT
{
#ifdef HAVE_ZLIB_H
struct z_stream_s z; /* Used to detect support for extensions. */
int have_rle = 0;
int have_fixed = 0;
start_new_program();
ADD_STORAGE(struct zipper);
pike.git/src/modules/Gz/zlibmod.c:1205: Inside #if defined(HAVE_ZLIB_H)
ADD_FUNCTION("uncompress",gz_uncompress,tFunc(tStr8 tOr(tVoid,tInt01),tStr8),0);
PIKE_MODULE_EXPORT(Gz, crc32);
PIKE_MODULE_EXPORT(Gz, zlibmod_pack);
PIKE_MODULE_EXPORT(Gz, zlibmod_unpack);
#else
HIDE_MODULE();
#endif
}
+ PIKE_MODULE_EXIT {}
+
#if defined(HAVE___VTBL__9TYPE_INFO) || defined(HAVE___T_9__NOTHROW)
/* Super-special kluge for IRIX 6.3 */
#ifdef HAVE___VTBL__9TYPE_INFO
extern void __vtbl__9type_info(void);
#endif /* HAVE___VTBL__9TYPE_INFO */
#ifdef HAVE___T_9__NOTHROW
extern void __T_9__nothrow(void);
#endif /* HAVE___T_9__NOTHROW */
/* Don't even think of calling this one
* Not static, so the compiler can't optimize it away totally.