The Prison Act,1894
Section 7. Temporary accommodation for prisoners
Whenever it appears to the Inspector General that the number of prisoners in any prison is greater than can conveniently or safely be kept therein, and it is not convenient to transfer the excess number to some other prison.
Or whenever from the outbreak of epidemic disease within any prison, or for any other reason, it is desirable to provide for the temporary shelter and safe custody of any prisoners,
Provision shall be made, by such officer and in such manner as the State Government may direct, for the shelter and safe custody in temporary prisons of so many of the prisoners as cannot be conveniently or safely kept in the prison.