Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add PerlIO_init_table() to initialise PL_perio
Previously, the PL_perio table was initialised by calling PerlIO_allocate, and throwing away the result. Since a slot with a null ->next was regarded as freed, the next call to PerlIO_allocate would reuse that slot, which is important, as STDIN etc are expected to occupy slots 1,2,3. Once reference counting of the slots is introduced, however, the first slot will leak, and STDIN etc will be assigned to the wrong slots. So do it properly now.
- Loading branch information