Theory of inactivation and reactivation of transforming DNA