He could have easily been shot but, as he wrote in his memoirs, ‘against a certain death in prison, the thing is well worth the risk’