2001 Subaru Forester • AWD Manual • 70,000 miles

My husband and I recently bought a used 2001 Subaru Forester, manual transmission. The check engine light was on, so we had a full inspection done and replaced the oxygen sensor. This fixed the check engine light, but a day or two later, the light came back on. Not long after, about when the weather started to get colder, the engine began misfiring when cold.
I believe it's a misfire because it feels like it's jumping, or lurching, or having a hard time getting gas maybe (?) Both while idling and while driving. You can hear it almost coughing or sputtering through the tailpipe.
A faint burning smell also comes from the engine. Once the engine is warm, if you turn the car off and then back on, the problem will stop. I should also note that the check engine light flashes when this happens, but stops after the engine is warm.
Recently, the problem has started getting worse. The car needs atleast 5 minutes to warm up. If you try to drive while the check engine light is flashing, it's really difficult to accelerate, especially when going up hill or changing gears. Sometimes I'll have to turn the engine on and off numerous times before the problem will stop. Any idea what's going on?
Midwest forester
January 14, 2011.

Check out the related content below while we wait for the question to be answered by a professional mechanic.