Lines Matching refs:fp

176 	php_stream *fp;  in phar_file_action()  local
212 fp = phar_get_efp(info, 1 TSRMLS_CC); in phar_file_action()
214 if (!fp) { in phar_file_action()
223 fp = phar_get_efp(info, 1 TSRMLS_CC); in phar_file_action()
229 got = php_stream_read(fp, buf, MIN(8192, info->uncompressed_filesize - position)); in phar_file_action()
1415 php_stream *fp; member
1425 php_stream *fp; in phar_build() local
1449 php_stream_from_zval_no_verify(fp, value); in phar_build()
1451 if (!fp) { in phar_build()
1639 fp = php_stream_open_wrapper(fname, "rb", STREAM_MUST_SEEK|0, &opened); in phar_build()
1641 if (!fp) { in phar_build()
1670 php_stream_close(fp); in phar_build()
1693 php_stream_close(fp); in phar_build()
1704 php_stream_close(data->internal_file->fp); in phar_build()
1707 data->internal_file->fp = NULL; in phar_build()
1709 data->internal_file->offset_abs = data->internal_file->offset = php_stream_tell(p_obj->fp); in phar_build()
1710 data->fp = NULL; in phar_build()
1711 phar_stream_copy_to_stream(fp, p_obj->fp, PHP_STREAM_COPY_ALL, &contents_len); in phar_build()
1713 php_stream_tell(p_obj->fp) - data->internal_file->offset; in phar_build()
1717 php_stream_close(fp); in phar_build()
1830 pass.fp = php_stream_fopen_tmpfile(); in PHP_METHOD()
1831 if (pass.fp == NULL) { in PHP_METHOD()
1841 php_stream_close(pass.fp); in PHP_METHOD()
1853 phar_obj->arc.archive->ufp = pass.fp; in PHP_METHOD()
1866 php_stream_close(pass.fp); in PHP_METHOD()
1914 pass.fp = php_stream_fopen_tmpfile(); in PHP_METHOD()
1915 if (pass.fp == NULL) { in PHP_METHOD()
1921 phar_obj->arc.archive->ufp = pass.fp; in PHP_METHOD()
1928 php_stream_close(pass.fp); in PHP_METHOD()
1974 static int phar_copy_file_contents(phar_entry_info *entry, php_stream *fp TSRMLS_DC) /* {{{ */ in phar_copy_file_contents()
1994 offset = php_stream_tell(fp); in phar_copy_file_contents()
2001 …if (SUCCESS != phar_stream_copy_to_stream(phar_get_efp(link, 0 TSRMLS_CC), fp, link->uncompressed_… in phar_copy_file_contents()
2009 entry->cfp = entry->fp; in phar_copy_file_contents()
2010 entry->fp = NULL; in phar_copy_file_contents()
2127 (*pphar)->fp = phar->fp; in phar_rename_archive()
2128 phar->fp = NULL; in phar_rename_archive()
2253 phar->fp = php_stream_fopen_tmpfile(); in phar_convert_to_other()
2254 if (phar->fp == NULL) { in phar_convert_to_other()
2280 php_stream_close(phar->fp); in phar_convert_to_other()
2301 if (FAILURE == phar_copy_file_contents(&newentry, phar->fp TSRMLS_CC)) { in phar_convert_to_other()
2303 php_stream_close(phar->fp); in phar_convert_to_other()
2346 if (phar->fp) { in phar_convert_to_other()
2347 php_stream_close(phar->fp); in phar_convert_to_other()
3518 php_stream_close(newentry.fp); in PHP_METHOD()
3652 contents_len = php_stream_write(data->fp, cont_str, cont_len); in phar_add_file()
3662 phar_stream_copy_to_stream(contents_file, data->fp, PHP_STREAM_COPY_ALL, &contents_len); in phar_add_file()
3904 php_stream *fp; in PHP_METHOD() local
3917 …if (phar_obj->arc.archive->fp && !phar_obj->arc.archive->is_brandnew && !(stub->flags & PHAR_ENT_C… in PHP_METHOD()
3918 fp = phar_obj->arc.archive->fp; in PHP_METHOD()
3920 if (!(fp = php_stream_open_wrapper(phar_obj->arc.archive->fname, "rb", 0, NULL))) { in PHP_METHOD()
3928 filter = php_stream_filter_create(filter_name, NULL, php_stream_is_persistent(fp) TSRMLS_CC); in PHP_METHOD()
3936 php_stream_filter_append(&fp->readfilters, filter); in PHP_METHOD()
3940 if (!fp) { in PHP_METHOD()
3946 php_stream_seek(fp, stub->offset_abs, SEEK_SET); in PHP_METHOD()
3955 if (phar_obj->arc.archive->fp && !phar_obj->arc.archive->is_brandnew) { in PHP_METHOD()
3956 fp = phar_obj->arc.archive->fp; in PHP_METHOD()
3958 fp = php_stream_open_wrapper(phar_obj->arc.archive->fname, "rb", 0, NULL); in PHP_METHOD()
3961 if (!fp) { in PHP_METHOD()
3967 php_stream_rewind(fp); in PHP_METHOD()
3971 if (len != php_stream_read(fp, buf, len)) { in PHP_METHOD()
3972 if (fp != phar_obj->arc.archive->fp) { in PHP_METHOD()
3973 php_stream_close(fp); in PHP_METHOD()
3986 if (fp != phar_obj->arc.archive->fp) { in PHP_METHOD()
3987 php_stream_close(fp); in PHP_METHOD()
4116 php_stream *fp; in phar_extract_file() local
4246 fp = php_stream_open_wrapper(fullpath, "w+b", REPORT_ERRORS|ENFORCE_SAFE_MODE, NULL); in phar_extract_file()
4248 fp = php_stream_open_wrapper(fullpath, "w+b", REPORT_ERRORS, NULL); in phar_extract_file()
4251 if (!fp) { in phar_extract_file()
4265 php_stream_close(fp); in phar_extract_file()
4273 php_stream_close(fp); in phar_extract_file()
4277 …if (SUCCESS != phar_stream_copy_to_stream(phar_get_efp(entry, 0 TSRMLS_CC), fp, entry->uncompresse… in phar_extract_file()
4280 php_stream_close(fp); in phar_extract_file()
4284 php_stream_close(fp); in phar_extract_file()
4304 php_stream *fp; in PHP_METHOD() local
4320fp = php_stream_open_wrapper(phar_obj->arc.archive->fname, "rb", IGNORE_URL|STREAM_MUST_SEEK, &act… in PHP_METHOD()
4322 if (!fp) { in PHP_METHOD()
4329 php_stream_close(fp); in PHP_METHOD()
4851 php_stream *fp; in PHP_METHOD() local
4879 if (!(fp = phar_get_efp(link, 0 TSRMLS_CC))) { in PHP_METHOD()
4888 …Z_STRLEN_P(return_value) = php_stream_copy_to_mem(fp, &(Z_STRVAL_P(return_value)), link->uncompres… in PHP_METHOD()
5079 if (!entry_obj->ent.entry->fp) { in PHP_METHOD()