1--TEST--
2Bug #44394 (Last two bytes missing from output) with session.use_trans_id
3--SKIPIF--
4<?php if (!extension_loaded("session")) print "skip"; ?>
5--INI--
6session.name=PHPSESSID
7session.use_only_cookies=0
8--FILE--
9<?php
10
11ini_set('session.use_trans_sid', 1);
12session_save_path(__DIR__);
13session_start();
14
15ob_start();
16
17$string = "<a href='a?q=1'>asd</a>";
18
19output_add_rewrite_var('a', 'b');
20
21echo $string;
22
23ob_flush();
24
25ob_end_clean();
26
27?>
28--CLEAN--
29<?php
30foreach (glob(__DIR__ . '/sess_*') as $filename) {
31  unlink($filename);
32}
33?>
34--EXPECTF--
35<a href='a?q=1&PHPSESSID=%s&a=b'>asd</a>
36