Ruby 3.0.5p211 (2022-11-24 revision ba5cf0f7c52d4d35cc6a173c89eda98ceffa2dcf)
Functions
gzwrite.c File Reference
#include "gzguts.h"
#include <stdarg.h>

Go to the source code of this file.

Functions

int gz_init OF ((gz_statep))
 
int gz_comp OF ((gz_statep, int))
 
int gz_zero OF ((gz_statep, z_off64_t))
 
z_size_t gz_write OF ((gz_statep, voidpc, z_size_t))
 
int gz_init (gz_statep state)
 
int gz_comp (gz_statep state, int flush)
 
int gz_zero (gz_statep state, z_off64_t len)
 
z_size_t gz_write (gz_statep state, voidpc buf, z_size_t len)
 
int ZEXPORT gzwrite (gzFile file, voidpc buf, unsigned len)
 
z_size_t ZEXPORT gzfwrite (voidpc buf, z_size_t size, z_size_t nitems, gzFile file)
 
int ZEXPORT gzputc (gzFile file, int c)
 
int ZEXPORT gzputs (gzFile file, const char *s)
 
int ZEXPORTVA gzvprintf (gzFile file, const char *format, va_list va)
 
int ZEXPORTVA gzprintf (gzFile file, const char *format,...)
 
int ZEXPORT gzflush (gzFile file, int flush)
 
int ZEXPORT gzsetparams (gzFile file, int level, int strategy)
 
int ZEXPORT gzclose_w (gzFile file)
 

Function Documentation

◆ gz_comp()

int gz_comp ( gz_statep  state,
int  flush 
)

◆ gz_init()

int gz_init ( gz_statep  state)

◆ gz_write()

z_size_t gz_write ( gz_statep  state,
voidpc  buf,
z_size_t  len 
)

Definition at line 187 of file gzwrite.c.

References gz_comp(), gz_init(), gz_zero(), state::in, len, memcpy, z_const, and Z_NO_FLUSH.

Referenced by gzfwrite(), gzputc(), gzputs(), and gzwrite().

◆ gz_zero()

int gz_zero ( gz_statep  state,
z_off64_t  len 
)

Definition at line 154 of file gzwrite.c.

References GT_OFF, gz_comp(), state::in, len, Z_NO_FLUSH, and z_off64_t.

Referenced by gz_write(), gzclose_w(), gzflush(), gzputc(), gzsetparams(), and gzvprintf().

◆ gzclose_w()

int ZEXPORT gzclose_w ( gzFile  file)

Definition at line 639 of file gzwrite.c.

References deflateEnd(), free, gz_comp(), gz_error(), GZ_WRITE, gz_zero(), if(), state::in, NULL, state::out, Z_ERRNO, Z_FINISH, Z_OK, and Z_STREAM_ERROR.

Referenced by gzclose().

◆ gzflush()

int ZEXPORT gzflush ( gzFile  file,
int  flush 
)

Definition at line 565 of file gzwrite.c.

References gz_comp(), GZ_WRITE, gz_zero(), NULL, Z_FINISH, Z_OK, and Z_STREAM_ERROR.

◆ gzfwrite()

z_size_t ZEXPORT gzfwrite ( voidpc  buf,
z_size_t  size,
z_size_t  nitems,
gzFile  file 
)

Definition at line 283 of file gzwrite.c.

References gz_error(), GZ_WRITE, gz_write(), len, NULL, Z_OK, and Z_STREAM_ERROR.

◆ gzprintf()

int ZEXPORTVA gzprintf ( gzFile  file,
const char *  format,
  ... 
)

Definition at line 463 of file gzwrite.c.

References gzvprintf().

◆ gzputc()

int ZEXPORT gzputc ( gzFile  file,
int  c 
)

Definition at line 313 of file gzwrite.c.

References GZ_WRITE, gz_write(), gz_zero(), state::in, NULL, and Z_OK.

◆ gzputs()

int ZEXPORT gzputs ( gzFile  file,
const char *  s 
)

Definition at line 361 of file gzwrite.c.

References gz_error(), GZ_WRITE, gz_write(), int(), len, NULL, strlen(), Z_OK, and Z_STREAM_ERROR.

◆ gzsetparams()

int ZEXPORT gzsetparams ( gzFile  file,
int  level,
int  strategy 
)

Definition at line 597 of file gzwrite.c.

References deflateParams(), gz_comp(), GZ_WRITE, gz_zero(), NULL, Z_BLOCK, Z_OK, and Z_STREAM_ERROR.

◆ gzvprintf()

int ZEXPORTVA gzvprintf ( gzFile  file,
const char *  format,
va_list  va 
)

Definition at line 391 of file gzwrite.c.

References gz_comp(), gz_init(), GZ_WRITE, gz_zero(), if(), state::in, len, memmove(), NULL, strlen(), vsnprintf, Z_NO_FLUSH, Z_OK, and Z_STREAM_ERROR.

Referenced by gzprintf().

◆ gzwrite()

int ZEXPORT gzwrite ( gzFile  file,
voidpc  buf,
unsigned  len 
)

Definition at line 255 of file gzwrite.c.

References gz_error(), GZ_WRITE, gz_write(), len, NULL, Z_DATA_ERROR, and Z_OK.

Referenced by ozstream::close(), operator<(), and ozstream::os_flush().

◆ OF() [1/4]

int gz_init OF ( (gz_statep )

◆ OF() [2/4]

int gz_comp OF ( (gz_statep, int )

◆ OF() [3/4]

◆ OF() [4/4]