"Go" C + + use Zlib library (-)

Source: Internet
Author: User

From: http://blog.chinaunix.net/uid-24607609-id-2118143.html today saw a gzopen function, searched his series of functions, and related usage C + + use Zlib library (-) 2010-10-07 09:37:35

Category: C/

1, Gzopen Open the zlib algorithm compressed files
Gzfile GZ = gzopen (char* filename, "RB");
Opens a zlib stream that allows you to read the file using that stream
2. Gzeof usage is similar to the feof in C and determines whether the end of the file is reached.
int gzeof (Gzfile gz);
3. Gzread reading data from a file
int Gzread (gzfile file, VOIDP buffer, unsigned len);
4, int gzgetc (Gzfile gz)
Read a character from a file
5, char* gzgets (gzfile file, char* buffer, int len)
Read len-1 characters from a file, or a line of characters

Category: C/

1, Gzopen Open the zlib algorithm compressed files
Gzfile GZ = gzopen (char* filename, "RB");
Opens a zlib stream that allows you to read the file using that stream
2. Gzeof usage is similar to the feof in C and determines whether the end of the file is reached.
int gzeof (Gzfile gz);
3. Gzread reading data from a file
int Gzread (gzfile file, VOIDP buffer, unsigned len);
4, int gzgetc (Gzfile gz)
Read a character from a file
5, char* gzgets (gzfile file, char* buffer, int len)
Read len-1 characters from a file, or a line of characters

"Go" C + + use Zlib library (-)

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.