Energy Transfer Equity’s acquisition of a rival pipeline company, Williams Companies, has turned into a nightmare as troubles in the energy industry worsen.

The risks around the deal have increased. Energy Transfer’s stock has plummeted, and executives at the company are searching for a way out.

Energy Transfer has only itself to blame, but how can it escape its troublesome deal?

Let’s start with the simple fact that Energy Transfer is not actually acquiring Williams. Instead, a newly created affiliate, Energy Transfer Corporation, is making the acquisition.

As part of the acquisition, Energy Transfer will pay up to $6 billion in cash and the remainder of the deal consideration in stock of the new affiliate. In return for paying this amount, the affiliate will acquire Williams and contribute all of Williams’s assets and liabilities to Energy Transfer in exchange for stock in Energy Transfer. As a result, Williams’s shareholders will own stock in a publicly traded entity –Transfer Corporation — whose only asset is Energy Transfer stock.