That is one of those times, where if you're fast enough, you Save the game, and then you can go back in and review. Now, what you describe leaves two possibilities, both of which I have encountered. The first is that you torpedoed the escort, and it had not fully sunk yet, and being armed with torpedo tubes, was able to get off a spread at your boat. We'll call that unlikely. The second possibility is "friendly fire", from your own boat, with a circle runner. While the Mark 18 did most of the circle runs, the 14 was not immune to them. In fact, none of the US torpedoes were immune to them, since they did not use vane limiters on their rudders. Even the stock game with "Dud torpedoes" turned off will still throw a circle runner your way every few thousand of shots. That would be my guess of the source of your torpedo impact. I have a video somewhere of a torpedo doing 3 or 4 circles near my boat before it ran out of fuel. I almost did not get away from it. I also have several videos where I did not get away, but in most instances, I was hit on the first circle...
Edit: This might be it