Depending on the optimizer you used, it might store some internal states like adaptive moments.
Since branch B was trained before, these states (momentum etc.) might still update the branch even if the current gradients are zero.
Which optimizer did you use?