Maybe these two things. 1) Treinen had already walked 5 batters and had runners on first and third. Leave him in and there is a higher possiblity of a walk loading the bases. Bringing Barrett in he would have the freedom/room of pitching to the first batter he sees and not have the pressure of a walk forcing in a run. No different a situation than that faced by Treinen.
2) McCatty told Williams Treinen was done. Well that's my whole point, why is he suddenly done? Nothing in his performance indicated "done".