Anadarko Petroleum (APC) , the fifth largest publicly-traded independent oil & gas company on the market, saw shares trading nearly three percent higher on Wednesday on volume well above average.

The jump for Anadarko is the direct result of David Einhorn’s announcement that his Greenlight Capital fund would be buying into the company at $78.55 per share. While the size of the position remains unrevealed for the time being, the buy-in price is only about $5 more than the company’s 52-week low, and substantially lower than the $81.55 at which shares opened Wednesday trading.

Greenlight is taking advantage of the company’s recent legal troubles to buy into Anadarko at a discount. Upcoming damages-payments resulting from litigation over the company’s alleged attempt to spin-off its environmental clean-up unit into a standalone company that was then allowed to go bankrupt under the weight of repairing 2,000 sites for which its parent company had previously been responsible, could add up to costs of between $5 and $14 billion.

Thus, while the stock has seen somewhat of an exodus, with institutional ownership ticking down in recent months, and shares unloading nearly a fifth of their price in the current quarter.

No better time then for Greenlight to get a good deal on one of the US’s premiere independent oil and gas producers, especially if the legal penalties end up being in the $5 billion range.

Even in the event that Anadarko is on the hook for the maximum, however, Greenlight is confident about the company’s operations, saying that its “valuable upstream assets and exciting exploration prospects” would end up outweighing double-digit fines.

Shares for the $41 billion company were up 3 percent to $83.63 ahead of the closing bell.