He had no such accommodation, so he applied to Southwark council in south London as a homeless person.
The council decided that because he had accommodation in the prison, he was not "homeless" and would not become homeless until released.
A High Court judge granted a declaration that B was homeless. Prison accommodation simply did not count for the purposes of the definition of "homelessness". A prisoner had no tenancy, licence or other "right" to occupy his cell. Even if that was wrong, a cell could not be accommodation "reasonable to continue to occupy" when a prisoner was faced with the opportunity of early release. B was accordingly homeless and, given that the council accepted he had priority need, accommodation should have been provided.
Source
Housing Today
Reference
Not all prisoners are "homeless". Some will retain their homes while in custody. But a prisoner with no home to go to on release is homeless. At 28 days prior to release, or the first date of probable early release, the prisoner will become threatened with homelessness. If the prisoner is in priority need and has not become homeless intentionally, the local housing authority will need to take steps to secure accommodation so the prisoner can maximise the opportunity for early release.