Updated from 11:54 a.m. EDT

Oil prices rose slightly Wednesday, after contradictory reports were released on energy inventories.

The benchmark U.S. crude closed 14 cents higher at $40.58 a barrel, after falling more than 2% Tuesday. Gasoline prices fell by a third of one cent to $1.243 a gallon.

The American Petroleum Institute said oil stockpiles rose slightly in the week ended July 16, while the Department of Energy's weekly survey reported a decline of 3.6 million barrels.

Traders remain concerned about the outlook for short-term supplies, despite recent moves to steady the market.

The Organization of Petroleum Exporting Countries last week said it had decided on an increase of its production ceiling by a half-million barrels a day in August and also canceled a July 21 meeting on the issue.

The measure was part of a broader agreement reached at OPEC's June 3 meeting, when it decided to increase official production by 2 million barrels a day in July. Prices touched a record high of more than $42 a barrel right before that meeting.

The August increase will put OPEC's official production ceiling at 26 million barrels a day, although its members routinely produce more than their individual quotas. A recent International Energy Agency report said the cartel produced more than 28 million barrels a day in July, when its ceiling was just 23.5 million barrels a day.

At one point recently, oil prices had fallen 15% from their record high, closing below $36 a barrel in June.

Since then, prices have bounced back on worries about production levels in such major oil-producing countries as Iraq, Norway, Nigeria and Russia, as well as terror attacks on the U.S. ahead of the presidential election.

During May, traders relentlessly bid up prices on short-term supply concerns triggered by strong global demand and terror attacks on oil-industry personnel and facilities in the Persian Gulf region. This happened ahead of the peak summer driving season in the U.S. and Europe.