They ended one of the longest scoring droughts in franchise history, built a 2-0 lead, and seemed to be coasting to their first win in their last seven home games.

But nothing comes easy for the Flyers these days.

They needed overtime, but they ended their home-ice misery.

Rookie Shayne Gostisbehere scored on a one-timer, a power-play blast 24 seconds into overtime, as the Flyers outlasted Carolina, 3-2, at the Wells Fargo Center on Monday night.

It was Gostisbehere's second career goal, and it was set up by Claude Giroux's third point of the night.

"The third period wasn't our best period . . . but it was huge for us to get the two points," said Gostisbehere, whose team has points in four of the five games he has played since being promoted from the Phantoms. "I'm still pinching myself a little bit to get such a big goal."

The Flyers capitalized 13 seconds after Victor Rask was penalized for holding Sean Couturier's stick.

Carolina overcame a 2-0 deficit and tied it on a pair of late rebound goals, scored by Victor Rask with 12 minutes, 2 seconds left, and Brett Pesce (after a Hurricanes faceoff win) with 3:45 remaining.

Before that, Michal Neuvirth was closing in on his fourth shutout of the young season.

Brayden Schenn, frustrated by two near-misses earlier in the game, had given the Flyers the lead when he scored a power-play goal midway through the second period.

The goal ended a 167:54 slump without a goal, the fifth-longest in franchise history.

"By my estimation, we had 12, 13, 14 scoring chances in the second period - maybe more - so it was nice to have one go in," coach Dave Hakstol said. "It's obviously been a while."

Schenn, stationed in the slot, redirected a perfect feed from a patient Jake Voracek with 9:40 remaining in the second period.

"We haven't been scoring, but we've been getting a ton of chances," Schenn said. "We just have to keep working at it and the goals will come."

Just 4:52 after Schenn's sixth goal, Giroux made it 2-0 with the Flyers' first shorthanded score of the season. The Flyers had a two-on-one and Eddie Lack stopped Sean Couturier's left-circle shot, but Giroux tapped in the rebound for his seventh goal this season.

Earlier in the second period, Schenn hit the post on a rebound while the Flyers were on a power play, prolonging the shutout agony.

With 2:54 left in the first period, Schenn had a great chance as he went in on a breakaway, was hooked from behind by Noah Hanifin, and was awarded a penalty shot. But Schenn got too close to Lack, making it easy for the backup goalie to stop his backhander.

Flyers winger Sam Gagner went to the locker room for repairs with 11:20 remaining in the opening period after being checked in the corner by Brad Malone. Gagner appeared to get cut by his own visor, and he left the ice with blood dripping from his face. He missed the rest of the game.

About two minutes later, Pierre-Edouard Bellemare, trying to get retribution for his teammate, got into a fight with Malone. Bellemare landed some early punches, but Malone then scored with a flurry of rights. Both went to the penalty box.

Desperate to get some production from his team's anemic offense, Hakstol juggled two lines and split up Giroux and Voracek.

Voracek dropped from the first line to the third unit, and was alongside Bellemare and Chris VandeVelde for most of the game, though the lines were scrambled because of Gagner's injury.

Voracek, the league's No. 4 scorer last season, said he was not upset at his demotion. For the first time this season, Giroux centered a line that included Michael Raffl and Schenn.

Hakstol was pleased with the Flyers' overall game, especially the first two periods, when they outshot the Hurricanes, 29-16, before going into a third-period defensive shell.

"We just have to keep pushing on all areas of our game," Hakstol said. "You can't push fast-forward; just have to keep working day by day."