Rex Energy Corp. said this week it has entered an arrangement with BP plc subsidiary BP Energy Co. to market most of its natural gas liquids in the company’s Butler Operated Area in western Pennsylvania and a portion of natural gas in the Warrior North Area of eastern Ohio.

Rex CEO Tom Stabley said the deal with BP was six months in the making. The company expects to protect and stabilize quarterly cash flows by beefing up its existing relationship with BP when the new arrangement goes into effect in January. The company said the pricing structure compares favorably to projected 2017 prices, and said the deal should mitigate summer and winter price swings.

Rex has already been able to reduce outstanding letters of credit by $14.1 million, but executives didn’t offer specifics about how the deal actually works. BP would also market a portion of Rex gas in the Warrior North Area of Carroll County, OH. BP has perennially topped NGI’s Top North American Gas Marketers Ranking, most recently reporting 22.53 Bcf/d in 1Q2017. Rex also inked a term condensate agreement in the Warrior North with refiner Marathon Petroleum Corp. that it said would improve its differential.

“We continue to be proactive in exploring other enhancements, which include further reductions in our letters of credit to create additional capital for growth, potential noncore asset sales and additional enhancements to our marketing agreements,” Stabley said.

The deals come as Rex has seen improvements to its average realized prices. More exposure to the Gulf Coast, along with improved differentials in the Northeast this year, helped lift liquids prices across the board. Including hedges, the company’s realized gas price also increased slightly to $2.78/Mcf in the second quarter, up from $2.73/Mcf during 2Q2016.

The company hit snags operationally during the period that cut its year/year production growth. Rex produced 177.1. MMcfe/d in the second quarter, compared with 199.1 MMcfe/d in 2Q2016 and 173.4 MMcfe/d in 1Q2017. Unplanned midstream maintenance and a compressor that was late to come online in the Moraine East Area in northern Butler County hampered production.

As a result, the company cut its full-year guidance to 180-190 MMcfe/d from the previous range of 194-204 MMcfe/d. Management still expects to hit 2018 guidance of 255-265 MMcfe/d with the Moraine compressor scheduled to come online in January.

Rex also highlighted 12 wells in various stages of development at the end of the second quarter in the Moraine East, which it acquired in a broader 2014 deal. The wells represent the company’s final efforts to delineate the field.

The company sold a water line in Carroll County that serves its Warrior North Area to Keystone Clearwater Services (KCS) for $8 million. It entered a lease agreement with KCS to secure future services in the field.

Revenue was up 52% year/year to $47.5 million in the second quarter, but it didn’t top expenses for the period. Rex reported a net loss of $10.2 million (minus $1.03/share), compared with net income of $16 million (22 cents) in 2Q2016.