A person who is serving a sentence of imprisonment for an offence against a law of the Commonwealth or of a Territory, or is otherwise subject to detention under a law of the Commonwealth or of a Territory, is taken to continue to serve that sentence of imprisonment, or to continue to be subject to that detention, at any time during which the person:
(a) is released from a prison pursuant to a request by a Tribunal under section 36; and
(b) is in custody in connection with the request (including custody outside Australia).