Find this useful? Enter your email to receive occasional updates for securing PHP code.

Signing you up...

Thank you for signing up!

PHP Decode

--TEST-- Bug #81346 (Non-seekable streams don't update position after write) --DESCRIPTION..

Decoded Output download

--TEST--
Bug #81346 (Non-seekable streams don't update position after write)
--DESCRIPTION--
The test expectation is due to bug #81345.
--EXTENSIONS--
bz2
--FILE--
<?php
$s = fopen("compress.bzip2://" . __DIR__ . "/bug81346.bz2", "w");
fwrite($s, str_repeat("hello world", 100));
fflush($s);
var_dump(ftell($s));
?>
--CLEAN--
<?php
@unlink(__DIR__ . "/bug81346.bz2");
?>
--EXPECT--
int(1100)

Did this file decode correctly?

Original Code

--TEST--
Bug #81346 (Non-seekable streams don't update position after write)
--DESCRIPTION--
The test expectation is due to bug #81345.
--EXTENSIONS--
bz2
--FILE--
<?php
$s = fopen("compress.bzip2://" . __DIR__ . "/bug81346.bz2", "w");
fwrite($s, str_repeat("hello world", 100));
fflush($s);
var_dump(ftell($s));
?>
--CLEAN--
<?php
@unlink(__DIR__ . "/bug81346.bz2");
?>
--EXPECT--
int(1100)

Function Calls

None

Variables

None

Stats

MD5 28208289c8e9e36f2ff042475477648a
Eval Count 0
Decode Time 93 ms