Lines Matching refs:newfile
2547 php_stream *file, *oldfile, *newfile; in phar_flush_ex() local
2595 newfile = php_stream_fopen_tmpfile(); in phar_flush_ex()
2596 if (!newfile) { in phar_flush_ex()
2613 php_stream_close(newfile); in phar_flush_ex()
2625 len != php_stream_write(newfile, ZSTR_VAL(user_stub), len) in phar_flush_ex()
2626 || end_sequence_len != php_stream_write(newfile, end_sequence, end_sequence_len) in phar_flush_ex()
2631 php_stream_close(newfile); in phar_flush_ex()
2643 php_stream_copy_to_stream_ex(oldfile, newfile, phar->halt_offset, &written); in phar_flush_ex()
2648 written = php_stream_write(newfile, ZSTR_VAL(new_stub), phar->halt_offset); in phar_flush_ex()
2654 php_stream_close(newfile); in phar_flush_ex()
2671 manifest_ftell = php_stream_tell(newfile); in phar_flush_ex()
2757 php_stream_close(newfile); in phar_flush_ex()
2777 php_stream_close(newfile); in phar_flush_ex()
2804 php_stream_close(newfile); in phar_flush_ex()
2815 php_stream_close(newfile); in phar_flush_ex()
2826 php_stream_close(newfile); in phar_flush_ex()
2879 if (sizeof(manifest) != php_stream_write(newfile, manifest, sizeof(manifest)) in phar_flush_ex()
2880 || (size_t)phar->alias_len != php_stream_write(newfile, phar->alias, phar->alias_len)) { in phar_flush_ex()
2886 php_stream_close(newfile); in phar_flush_ex()
2899 …if (4 != php_stream_write(newfile, manifest, 4) || ((main_metadata_str.s ? ZSTR_LEN(main_metadata_… in phar_flush_ex()
2900 …&& ZSTR_LEN(main_metadata_str.s) != php_stream_write(newfile, ZSTR_VAL(main_metadata_str.s), ZSTR_… in phar_flush_ex()
2907 php_stream_close(newfile); in phar_flush_ex()
2919 manifest_ftell = php_stream_tell(newfile); in phar_flush_ex()
2936 if (4 != php_stream_write(newfile, entry_buffer, 4) in phar_flush_ex()
2937 || entry->filename_len != php_stream_write(newfile, entry->filename, entry->filename_len) in phar_flush_ex()
2938 || (entry->is_dir && 1 != php_stream_write(newfile, "/", 1))) { in phar_flush_ex()
2942 php_stream_close(newfile); in phar_flush_ex()
2971 if (sizeof(entry_buffer) != php_stream_write(newfile, entry_buffer, sizeof(entry_buffer)) in phar_flush_ex()
2973 …ZSTR_LEN(metadata_str) != php_stream_write(newfile, ZSTR_VAL(metadata_str), ZSTR_LEN(metadata_str)… in phar_flush_ex()
2978 php_stream_close(newfile); in phar_flush_ex()
2989 if(1 != php_stream_write(newfile, manifest, 1)) { in phar_flush_ex()
2994 php_stream_close(newfile); in phar_flush_ex()
3005 offset = php_stream_tell(newfile); in phar_flush_ex()
3020 php_stream_close(newfile); in phar_flush_ex()
3032 php_stream_close(newfile); in phar_flush_ex()
3042 if (php_stream_copy_to_stream_ex(file, newfile, entry->compressed_filesize, &wrote) == FAILURE) { in phar_flush_ex()
3047 php_stream_close(newfile); in phar_flush_ex()
3085 php_stream_rewind(newfile); in phar_flush_ex()
3097 if (FAILURE == phar_create_signature(phar, newfile, &digest, &digest_len, error)) { in phar_flush_ex()
3109 php_stream_close(newfile); in phar_flush_ex()
3113 php_stream_write(newfile, digest, digest_len); in phar_flush_ex()
3119 php_stream_write(newfile, sig_buf, 4); in phar_flush_ex()
3125 php_stream_write(newfile, sig_buf, 4); in phar_flush_ex()
3126 php_stream_write(newfile, "GBMB", 4); in phar_flush_ex()
3150 php_stream_rewind(newfile); in phar_flush_ex()
3154 phar->fp = newfile; in phar_flush_ex()
3158 phar->fp = newfile; in phar_flush_ex()
3182 php_stream_copy_to_stream_ex(newfile, phar->fp, PHP_STREAM_COPY_ALL, NULL); in phar_flush_ex()
3187 phar->fp = newfile; in phar_flush_ex()
3191 php_stream_copy_to_stream_ex(newfile, phar->fp, PHP_STREAM_COPY_ALL, NULL); in phar_flush_ex()
3196 phar->fp = newfile; in phar_flush_ex()
3198 php_stream_copy_to_stream_ex(newfile, phar->fp, PHP_STREAM_COPY_ALL, NULL); in phar_flush_ex()
3200 php_stream_close(newfile); in phar_flush_ex()