1--TEST-- 2Bug #81302 (Stream position after stream filter removed) 3--EXTENSIONS-- 4zlib 5--FILE-- 6<?php 7$f = fopen("php://memory", "w+b"); 8$z = stream_filter_append($f, "zlib.deflate", STREAM_FILTER_WRITE, 6); 9fwrite($f, "Testing"); 10stream_filter_remove($z); 11$pos = ftell($f); 12fseek($f, 0); 13$count = strlen(fread($f, 1024)); 14fclose($f); 15var_dump($count === $pos); 16?> 17--EXPECT-- 18bool(true) 19