Date: 11/22/98
- Next message: elvis <email protected>: "[PHP-DEV] Bug #940: Make Apache's and PHP3's regex to the same."
- Previous message: Bug Database: "[PHP-DEV] Bug #939 Updated: Automatically inserts a \ before a ' cuasing a \' on a post"
- Next in thread: jim: "[PHP-DEV] CVS update: php3/functions"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Sunday November 22, 1998 @ 8:02
Author: sr
Update of /repository/php3/functions
In directory asf:/u2/tmp/cvs-serv18921/functions
Modified Files:
zlib.c
Log Message:
Added proto comments from file.c to zlib.c.
Index: php3/functions/zlib.c
diff -c php3/functions/zlib.c:1.10 php3/functions/zlib.c:1.11
*** php3/functions/zlib.c:1.10 Wed Nov 11 18:19:05 1998
--- php3/functions/zlib.c Sun Nov 22 08:02:37 1998
***************
*** 22,28 ****
| Stefan Röhrich <sr <email protected>> |
+----------------------------------------------------------------------+
*/
! /* $Id: zlib.c,v 1.10 1998/11/11 23:19:05 cschneid Exp $ */
#if !PHP_31 && defined(THREAD_SAFE)
#undef THREAD_SAFE
#endif
--- 22,28 ----
| Stefan Röhrich <sr <email protected>> |
+----------------------------------------------------------------------+
*/
! /* $Id: zlib.c,v 1.11 1998/11/22 13:02:37 sr Exp $ */
#if !PHP_31 && defined(THREAD_SAFE)
#undef THREAD_SAFE
#endif
***************
*** 335,340 ****
--- 335,342 ----
return NULL;
}
+ /* {{{ proto array gzfile(string filename)
+ Read und uncompress entire .gz-file into an array */
void php3_gzfile(INTERNAL_FUNCTION_PARAMETERS) {
pval *filename, *arg2;
gzFile zp;
***************
*** 386,396 ****
}
}
gzclose(zp);
-
}
!
!
void php3_gzopen(INTERNAL_FUNCTION_PARAMETERS) {
pval *arg1, *arg2, *arg3;
gzFile *zp;
--- 388,398 ----
}
}
gzclose(zp);
}
! /* }}} */
+ /* {{{ proto int gzopen(string filename, string mode [, int use_include_path])
+ Open a .gz-file and return a .gz-file pointer */
void php3_gzopen(INTERNAL_FUNCTION_PARAMETERS) {
pval *arg1, *arg2, *arg3;
gzFile *zp;
***************
*** 421,427 ****
/*
* We need a better way of returning error messages from
! * php3_gzopen__wrapper().
*/
zp = php3_gzopen_wrapper(arg1->value.str.val, p, use_include_path|ENFORCE_SAFE_MODE);
if (!zp) {
--- 423,429 ----
/*
* We need a better way of returning error messages from
! * php3_gzopen_wrapper().
*/
zp = php3_gzopen_wrapper(arg1->value.str.val, p, use_include_path|ENFORCE_SAFE_MODE);
if (!zp) {
***************
*** 435,441 ****
--- 437,446 ----
efree(p);
RETURN_LONG(id);
}
+ /* }}} */
+ /* {{{ proto int gzclose(int zp)
+ Close an open .gz-file pointer */
void php3_gzclose(INTERNAL_FUNCTION_PARAMETERS) {
pval *arg1;
int id, type;
***************
*** 455,462 ****
php3_list_delete(id);
RETURN_TRUE;
}
!
void php3_gzeof(INTERNAL_FUNCTION_PARAMETERS) {
pval *arg1;
gzFile *zp;
--- 460,469 ----
php3_list_delete(id);
RETURN_TRUE;
}
! /* }}} */
+ /* {{{ proto int gzeof(int zp)
+ Test for end-of-file on a .gz-file pointer */
void php3_gzeof(INTERNAL_FUNCTION_PARAMETERS) {
pval *arg1;
gzFile *zp;
***************
*** 480,486 ****
--- 487,496 ----
RETURN_FALSE;
}
}
+ /* }}} */
+ /* {{{ proto string gzgets(int zp, int length)
+ Get a line from .gz-file pointer */
void php3_gzgets(INTERNAL_FUNCTION_PARAMETERS) {
pval *arg1, *arg2;
gzFile *zp;
***************
*** 518,524 ****
--- 528,537 ----
}
return;
}
+ /* }}} */
+ /* {{{ proto string gzgetc(int zp)
+ Get a character from .gz-file pointer */
void php3_gzgetc(INTERNAL_FUNCTION_PARAMETERS) {
pval *arg1;
gzFile *zp;
***************
*** 550,557 ****
--- 563,573 ----
}
return;
}
+ /* }}} */
/* Strip any HTML tags while reading */
+ /* {{{ proto string gzgetss(int zp, int length)
+ Get a line from file pointer and strip HTML tags */
void php3_gzgetss(INTERNAL_FUNCTION_PARAMETERS)
{
pval *fd, *bytes;
***************
*** 665,672 ****
RETVAL_STRING(rbuf,1);
efree(rbuf);
}
!
void php3_gzwrite(INTERNAL_FUNCTION_PARAMETERS) {
pval *arg1, *arg2, *arg3=NULL;
gzFile *zp;
--- 681,690 ----
RETVAL_STRING(rbuf,1);
efree(rbuf);
}
! /* }}} */
+ /* {{{ proto int gzwrite(int zp, string str [, int length])
+ Binary-safe .gz-file write */
void php3_gzwrite(INTERNAL_FUNCTION_PARAMETERS) {
pval *arg1, *arg2, *arg3=NULL;
gzFile *zp;
***************
*** 712,718 ****
--- 730,739 ----
ret = gzwrite(zp, arg2->value.str.val,num_bytes);
RETURN_LONG(ret);
}
+ /* }}} */
+ /* {{{ proto int gzrewind(int zp)
+ Rewind the position of a .gz-file pointer */
void php3_gzrewind(INTERNAL_FUNCTION_PARAMETERS) {
pval *arg1;
int id,type;
***************
*** 732,738 ****
--- 753,762 ----
gzrewind(zp);
RETURN_TRUE;
}
+ /* }}} */
+ /* {{{ proto int gztell(int zp)
+ Get .gz-file pointer's read/write position */
void php3_gztell(INTERNAL_FUNCTION_PARAMETERS) {
pval *arg1;
int id, type;
***************
*** 753,759 ****
--- 777,786 ----
pos = gztell(zp);
RETURN_LONG(pos);
}
+ /* }}} */
+ /* {{{ proto int gzseek(int zp, int offset)
+ Seek on a file pointer */
void php3_gzseek(INTERNAL_FUNCTION_PARAMETERS) {
pval *arg1, *arg2;
int ret,id,type;
***************
*** 776,785 ****
--- 803,815 ----
ret = gzseek(zp,pos,SEEK_SET);
RETURN_LONG(ret);
}
+ /* }}} */
/*
* Read a file and write the ouput to stdout
*/
+ /* {{{ proto int readgzfile(string filename [, int use_include_path])
+ Output a .gz-file */
void php3_readgzfile(INTERNAL_FUNCTION_PARAMETERS) {
pval *arg1, *arg2;
char buf[8192];
***************
*** 826,835 ****
--- 856,868 ----
gzclose(zp);
RETURN_LONG(size);
}
+ /* }}} */
/*
* Read to EOF on a file descriptor and write the output to stdout.
*/
+ /* {{{ proto int gzpassthru(int zp)
+ Output all remaining data from a .gz-file pointer */
void php3_gzpassthru(INTERNAL_FUNCTION_PARAMETERS) {
pval *arg1;
gzFile *zp;
***************
*** 858,864 ****
--- 891,900 ----
php3_list_delete(id);
RETURN_LONG(size);
}
+ /* }}} */
+ /* {{{ proto int gzread(int zp, int length)
+ Binary-safe file read */
void php3_gzread(INTERNAL_FUNCTION_PARAMETERS)
{
pval *arg1, *arg2;
***************
*** 890,895 ****
--- 926,932 ----
}
return_value->type = IS_STRING;
}
+ /* }}} */
#endif /* HAVE_ZLIB */
/*
-- PHP Development Mailing List http://www.php.net/ To unsubscribe send an empty message to php-dev-unsubscribe <email protected> For help: php-dev-help <email protected>
- Next message: elvis <email protected>: "[PHP-DEV] Bug #940: Make Apache's and PHP3's regex to the same."
- Previous message: Bug Database: "[PHP-DEV] Bug #939 Updated: Automatically inserts a \ before a ' cuasing a \' on a post"
- Next in thread: jim: "[PHP-DEV] CVS update: php3/functions"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

