Corrections Minister Judith Collins says she's been asking what happens when courts turn down public protection order requests for high-risk prisoners being released to the community.
She's also made the point that a lot of people in prisons would have been in mental health institutions that were closed or scaled back in the 1990s.
She made the comments on Q&A on Sunday as people living in Mangere fight to move a released child sex offender who is living near a school.
She says Corrections tried to get a public protection order for the released prisoner the Mangere community is concerned about, which would allow it to house him "outside the wire" on prison land, but was turned down by the High Court.
"That's the only one that they've applied for and been turned down for. It's only a new piece of legislation," she said.
She said she had talked to the Justice Minister Amy Adams "about what happens if they get turned down" because there are several other requests for public protection orders in the pipeline.
"Let's be frank here - before we got rid of the institutionalisation of the mental health system a lot of these people would have been actually housed there.
"In our wisdom in the '90s we decided to open up the institutional gates," she said.
Corrections has a legal obligation to house and reintegrate prisoners being released.
There is already a facility "outside the wire" at Christchurch Men's Prison and another facility being built there will be finished in November.
A law allowing public protection orders was passed in 2014. They are civil detention orders for individuals who have served a finite prison sentence, but still pose a very high risk of imminent and serious sexual or violent offending and cannot be safely managed in the community.
Only a very small number of people are likely to be subject to public protection orders, Corrections says.
Earlier this month Corrections agreed to move a released sex offender from the Lower Hutt suburb of Maungaraki to a residence on the grounds of Christchurch Men's Prison as an interim measure.