(4)On active service, a sentence of imprisonment may be carried out by confinement in such place as the officer commanding the forces in the field may from time to time appoint.Period of custody undergone by the officer of person to be set off against the imprisonment.