xref: /php-src/ext/bz2/tests/bug51997.phpt (revision 56f90492)
1--TEST--
2Bug #51997 (SEEK_CUR with 0 value, returns a warning)
3--EXTENSIONS--
4bz2
5--FILE--
6<?php
7
8error_reporting(E_ALL);
9
10$filename = "bug51997.bz2";
11$str = "This is a test string.\n";
12$bz = bzopen($filename, "w");
13bzwrite($bz, $str);
14bzclose($bz);
15
16$bz = bzopen($filename, "r");
17fseek($bz, 0, SEEK_CUR);
18print bzread($bz, 10);
19print bzread($bz);
20bzclose($bz);
21unlink($filename);
22?>
23--EXPECT--
24This is a test string.
25