search for: z_stream

Displaying 18 results from an estimated 18 matches for "z_stream".

Did you mean: _stream
2006 Feb 09
1
make: Target `all' not remade because of errors. (PR#8585)
.../pngconf.h:1091: error: parse error before '*' token /usr/include/pngconf.h:1092: error: parse error before '*' token /usr/include/pngconf.h:1093: error: parse error before '*' token In file included from rbitmap.c:45: /usr/include/png.h:1034: error: parse error before "z_stream" /usr/include/png.h:1262: error: parse error before '}' token /usr/include/png.h:1821: error: parse error before "png_zalloc" /usr/include/png.h:1821: error: parse error before "png_ptr" /usr/include/png.h:1825: error: parse error before "png_ptr" rbitmap....
2023 Feb 24
1
[PATCH 1/1] Add support for ZSTD compression
...+++ b/packet.c @@ -79,6 +79,9 @@ #ifdef WITH_ZLIB #include <zlib.h> #endif +#ifdef HAVE_LIBZSTD +#include <zstd.h> +#endif #include "xmalloc.h" #include "compat.h" @@ -156,6 +159,14 @@ struct session_state { /* Incoming/outgoing compression dictionaries */ z_stream compression_in_stream; z_stream compression_out_stream; +#endif +#ifdef HAVE_LIBZSTD + ZSTD_DCtx *compression_zstd_in_stream; + ZSTD_CCtx *compression_zstd_out_stream; + u_int64_t compress_zstd_in_raw; + u_int64_t compress_zstd_in_comp; + u_int64_t compress_zstd_out_raw; + u_int64_t compress_zstd...
2007 Apr 22
0
libswfdec/swfdec_swf_decoder.c
...9d6c..6c13e70 100644 --- a/libswfdec/swfdec_swf_decoder.c +++ b/libswfdec/swfdec_swf_decoder.c @@ -114,23 +114,28 @@ swfdec_swf_decoder_deflate_all (SwfdecSw return TRUE; } -static void +static gboolean swf_inflate_init (SwfdecSwfDecoder * s) { SwfdecDecoder *dec = SWFDEC_DECODER (s); z_stream *z; int ret; + guint8 *data; + data = g_try_malloc (dec->bytes_total - 8); + if (data == NULL) + return FALSE; + s->uncompressed_buffer = swfdec_buffer_new_for_data (data, dec->bytes_total - 8); z = &s->z; z->zalloc = zalloc; z->zfree = zfree; ret = inf...
2006 Feb 09
0
make: Target `all' not remade because of errors.
.../pngconf.h:1091: error: parse error before '*' token /usr/include/pngconf.h:1092: error: parse error before '*' token /usr/include/pngconf.h:1093: error: parse error before '*' token In file included from rbitmap.c:45: /usr/include/png.h:1034: error: parse error before "z_stream" /usr/include/png.h:1262: error: parse error before '}' token /usr/include/png.h:1821: error: parse error before "png_zalloc" /usr/include/png.h:1821: error: parse error before "png_ptr" /usr/include/png.h:1825: error: parse error before "png_ptr" rbitmap....
2007 Jan 18
0
Branch 'interpreter' - 4 commits - libswfdec/js libswfdec/swfdec_bits.c libswfdec/swfdec_bits.h libswfdec/swfdec_codec_screen.c libswfdec/swfdec_image.c libswfdec/swfdec_script.c libswfdec/swfdec_swf_decoder.c libswfdec/swfdec_tag.c
...44 --- a/libswfdec/swfdec_image.c +++ b/libswfdec/swfdec_image.c @@ -99,46 +99,30 @@ zfree (void *opaque, void *addr) g_free (addr); } -static void * -lossless (void *zptr, int zlen, int *plen) +static guint8 * +lossless (const guint8 *zptr, int zlen, int len) { - void *data; - int len; - z_stream *z; + guint8 *data; + z_stream z = { NULL, }; int ret; - z = g_new0 (z_stream, 1); - z->zalloc = zalloc; - z->zfree = zfree; - z->opaque = NULL; - - z->next_in = zptr; - z->avail_in = zlen; - - data = NULL; - len = 0; - ret = inflateInit (z); - while (z->avail_in...
2023 Feb 24
1
[PATCH 0/1] ZSTD compression support for OpenSSH
I added ZSTD support to OpenSSH roughly three years ago and I've been playing with it ever since. The nice part is that ZSTD achieves reasonable compression (like zlib) but consumes little CPU so it is unlikely that compression becomes the bottle neck of a transfer. The compression overhead (CPU) is negligible even when uncompressed data is tunneled over the SSH connection (SOCKS proxy, port
2020 Jul 10
0
Re: [PATCH nbdkit] New filter: gzip
...actually retire the plugin? > +++ b/filters/gzip/gzip.c > @@ -0,0 +1,347 @@ > +/* The first thread to call gzip_prepare uncompresses the whole plugin. */ > +static int > +do_uncompress (struct nbdkit_next_ops *next_ops, void *nxdata) > +{ > + int64_t compressed_size; > + z_stream strm; > + int zerr; > + const char *tmpdir; > + size_t len; > + char *template; > + CLEANUP_FREE char *in_block = NULL, *out_block = NULL; > + > + /* This was the same buffer size as used in the old plugin. As far > + * as I know it was chosen at random. > + */...
2020 Jul 10
2
[PATCH nbdkit] New filter: gzip
.../* Always pass readonly=1 to the underlying plugin. */ + if (next (nxdata, 1) == -1) + return NULL; + + return NBDKIT_HANDLE_NOT_NEEDED; +} + +/* Convert a zlib error (always negative) to an nbdkit error message, + * and return errno correctly. + */ +static void +zerror (const char *op, const z_stream *strm, int zerr) +{ + if (zerr == Z_MEM_ERROR) { + errno = ENOMEM; + nbdkit_error ("gzip: %s: %m", op); + } + else { + errno = EIO; + if (strm->msg) + nbdkit_error ("gzip: %s: %s", op, strm->msg); + else + nbdkit_error ("gzip: %s: unknown e...
2007 Jan 14
0
Changes to 'refs/tags/0.4.1'
...Shift in the right direction (oops) DO the right check when testing if the file is playable Merge branch 'master' of ssh://company@git.freedesktop.org/git/swfdec s/SwfdecCodec/SwfdecAudioCodec/ and introduce SwfdecVideoCodec add swfdec_bits_get_bu16 Make the z_stream part of the SwfdecDecoder struct rate == 0 is allowed now fix wrong type in macros remove \n from debugging messages fix RGB555 images append the right SwfdecContent to the list get the next_event time before comparing Fix includes add jpeg_rgb_decode...
2020 Mar 24
4
ZSTD compression support for OpenSSH
I hacked zstd support into OpenSSH a while ago and just started to clean it up in the recent days. The cleanup includes configuration support among other things that I did not have. During testing I noticed the following differences compared to zlib: - highly interactive shell output (as in refreshed at a _very_ high rate) may result in higher bandwidth compared to zlib. Since zstd is quicker
2020 Sep 05
8
[PATCH 0/5] ZSTD compression support for OpenSSH
I added ZSTD support to OpenSSH roughly over a year and I've been playing with it ever since. The nice part is that ZSTD achieves reasonable compression (like zlib) but consumes little CPU so it is unlikely that compression becomes the bottle neck of a transfer. The compression overhead (CPU) is negligible even when uncompressed data is tunneled over the SSH connection (SOCKS proxy, port
2007 Feb 13
0
9 commits - libswfdec/js libswfdec/swfdec_bits.c libswfdec/swfdec_bits.h libswfdec/swfdec_codec_screen.c libswfdec/swfdec_image.c libswfdec/swfdec_script.c test/Makefile.am test/swfdec_out.c test/swfdec_out.h test/swfedit.c test/swfedit_file.c
...image) { } - -static void * -zalloc (void *opaque, unsigned int items, unsigned int size) -{ - return g_malloc (items * size); -} - -static void -zfree (void *opaque, void *addr) -{ - g_free (addr); -} - -static guint8 * -lossless (const guint8 *zptr, int zlen, int len) -{ - guint8 *data; - z_stream z = { NULL, }; - int ret; - - z.zalloc = zalloc; - z.zfree = zfree; - z.opaque = NULL; - - data = g_malloc (len); - z.next_in = (Bytef *) zptr; - z.avail_in = zlen; - z.next_out = data; - z.avail_out = len; - - ret = inflateInit (&z); - ret = inflate (&z, Z_FINISH); - if (ret !=...
2002 Jan 30
1
Patch: update zlib/* to 1.1.3
...f your product. If for some reason you cannot @@ -608,11 +608,13 @@ deflate_state *ss; ushf *overlay; - ss = source->state; - if (source == Z_NULL || dest == Z_NULL || ss == Z_NULL) { + if (source == Z_NULL || dest == Z_NULL || source->state == Z_NULL) { return Z_STREAM_ERROR; } + + ss = source->state; + *dest = *source; ds = (deflate_state *) ZALLOC(dest, 1, sizeof(deflate_state)); Index: zlib/deflate.h =================================================================== RCS file: /cvsroot/rsync/zlib/deflate.h,v retrieving revision 1.1 diff...
2007 Jan 22
0
Branch 'interpreter' - 3 commits - libswfdec/swfdec_bits.c libswfdec/swfdec_swf_decoder.c test/Makefile.am test/swfedit.c test/swfedit_file.c test/swfedit_file.h test/swfedit_tag.c test/swfedit_tag.h test/swfedit_token.c test/swfedit_token.h
...id * +zalloc (void *opaque, unsigned int items, unsigned int size) +{ + return g_malloc (items * size); +} + +static void +zfree (void *opaque, void *addr) +{ + g_free (addr); +} + +static SwfdecBuffer * +swfenc_file_inflate (SwfdecBits *bits, guint size) +{ + SwfdecBuffer *decoded, *encoded; + z_stream z; + int ret; + + encoded = swfdec_bits_get_buffer (bits, -1); + if (encoded == NULL) + return NULL; + decoded = swfdec_buffer_new_and_alloc (size); + z.zalloc = zalloc; + z.zfree = zfree; + z.opaque = NULL; + z.next_in = encoded->data; + z.avail_in = encoded->length; + z.next_ou...
2011 Jan 21
0
Wine release 1.3.12
...OMNode iface. msxml3: Don't forward get_namespaceURI calls to node's IXMLDOMNode iface. urlmon: Store object instead of interface pointer to BindProtocol in Binding object. mshtml: Get rid of win9x test failures workarounds. wininet: Make sure to initialize the whole z_stream struct (valgrind). winnt.h: Use Common macro for __C89_NAMELESSUNION and __C89_NAMELESSSTRUCT. shlwapi: Fixed handling A->W buffer in UrlCanonicalizeA (valgrind). wininet: Added post data tests. wininet: Fixed memory leak in tests (valgrind). msxml3: Fixed memory le...
2012 Aug 20
13
[PATCH 00/12] Multidisk support
Hello, the following patches should get multidisk access working. The syntax accepted is the following: (hdx,y)/path/to/file where x is the disk number and start at 0 and the y is the partition number starting at 1. So (hd0,1) is the first partition of the first disk. the other accepted syntax is using MBR's 32 bits disk signature so for example: (mbr:0x12345678,2)/foo/bar would address
2007 Feb 06
0
109 commits - configure.ac libswfdec/js libswfdec/Makefile.am libswfdec/swfdec_bits.c libswfdec/swfdec_bits.h libswfdec/swfdec_buffer.c libswfdec/swfdec_button_movie.c libswfdec/swfdec_codec_screen.c libswfdec/swfdec_color.c libswfdec/swfdec_color.h
...index c9df0de..2810291 100644 --- a/libswfdec/swfdec_image.c +++ b/libswfdec/swfdec_image.c @@ -117,7 +117,7 @@ lossless (const guint8 *zptr, int zlen, z.avail_out = len; ret = inflateInit (&z); - ret = inflate (&z, Z_SYNC_FLUSH); + ret = inflate (&z, Z_FINISH); if (ret != Z_STREAM_END) { SWFDEC_WARNING ("lossless: ret == %d", ret); } @@ -348,9 +348,8 @@ static void swfdec_image_lossless_load (SwfdecImage *image) { int format; - int color_table_size; + guint color_table_size; unsigned char *ptr; - unsigned char *endptr; SwfdecBits bits; unsi...
2008 Jan 07
0
12 commits - configure.ac doc/swfdec.types Makefile.am test/crashfinder.c test/dump.c test/Makefile.am test/swfdec-extract.c test/swfdec_out.c test/swfdec_out.h test/swfedit.c test/swfedit_file.c test/swfedit_file.h test/swfedit_list.c test/swfedit_list.h
...id * -zalloc (void *opaque, unsigned int items, unsigned int size) -{ - return g_malloc (items * size); -} - -static void -zfree (void *opaque, void *addr) -{ - g_free (addr); -} - -static SwfdecBuffer * -swfenc_file_inflate (SwfdecBits *bits, guint size) -{ - SwfdecBuffer *decoded, *encoded; - z_stream z; - int ret; - - encoded = swfdec_bits_get_buffer (bits, -1); - if (encoded == NULL) - return NULL; - decoded = swfdec_buffer_new_and_alloc (size); - z.zalloc = zalloc; - z.zfree = zfree; - z.opaque = NULL; - z.next_in = encoded->data; - z.avail_in = encoded->length; - z.next_ou...