Earlier in his career, if Reilly Smith missed a wide-open net with his team behind by a goal, he might have put his head down, skated to the bench, and inwardly called himself some not-so-nice names.

But that was then and this is now. On Saturday night, Smith did miss an open net during an early third-period power play, but he also scored and set up Zdeno Chara for the winning tally as the Bruins edged the Pittsburgh Penguins, 3-2, at TD Garden.

In a first period filled with ugliness and injury, Smith was the lone bright spot for the home team. At 10:13, Smith tied the game at 1-1 on the Bruins’ first shot of the contest. Brad Marchand made it all work with terrific protection of the puck. He passed to Patrice Bergeron, who found Smith in the left circle.

It was Smith’s sixth goal of the season.

Get Sports Headlines in your inbox:

The Globe's most recent sports headlines delivered to your inbox every morning.

“I kind of just jumped on the ice,’’ said Smith. “Marshie went to the middle and passed it out to Bergie and Bergie fed it to the middle. I just tried to get the puck on net. I think it might have bounced off a couple of people but I was fortunate to see it hit the back of the net.’’

The Bruins found themselves down, 2-1, heading into the third period and were without Loui Eriksson (knocked out in the first period) and Shawn Thornton (ejected for his beating of Brooks Orpik) after already missing defensemen Johnny Boychuk (back injury) and Adam McQuaid (lower-body injury). But they found a way to battle back.

With Chris Kunitz off for tripping Dougie Hamilton at 3:43, the Bruins’ power play went to work. The Bruins got several good looks but the best was Smith’s shot with Marc-Andre Fleury down and out after making a save on Hamilton. Although the puck came close to going in, it wasn’t close enough.

“I probably could have taken a couple of extra seconds but I just tried to shoot it quick and it just hit the outside part of the mesh,’’ said Smith. “The puck was moving kind of quick but it’s no excuse, I should’ve buried it, but that stuff will happen.’’

But that didn’t keep Smith from thinking about it, at least a little bit, as he shook his head on the bench.

“I was just trying to regroup from it,’’ he said. “Stuff like that will happen in hockey. The biggest thing is not letting it bother you the next shift. In the past, I probably would’ve gotten down on myself a little bit but we needed a couple more goals so it wouldn’t have helped if I had negative emotions on the bench.

“Positivity helps when you come back [to the bench after] you’ve missed a great opportunity. It’s good to see we regrouped from that and kept on pushing the pace.’’

Turns out Smith’s close call didn’t matter after all. David Krejci made it all square at 18:31 and Chara played the role of hero with 13 seconds remaining, with Smith playing an important supporting role.

“It was great to see it hit the back of the net,’’ said Smith. “I got the puck on the wing and took it down low. Bergie and [Marchand] came over to support and it was a little bit of a scramble. It popped out to me and I saw [Chara] open in the middle so I just gave him the puck.

“If you get him the puck in that spot, he’s going to score more times than not. We were battling for probably the whole third period to start getting chances and it seemed like [in the last two minutes], we finally got it in. To see [Krejci’s] and then to have Chara get that last one was huge.’’

Smith said he had faith his team could rally when it counted.

“I’ve never really played on a team like this [one], that never gives up,’’ said Smith. “It’s great having this type of drive and this type of leadership. [The Penguins] came back last time we played them and tied the game up late, so I guess it was our turn.’’

BostonGlobe.com complimentary digital access has been provided to you, without a subscription, for free starting today and ending in 14 days. After the free trial period, your free BostonGlobe.com digital access will stop immediately unless you sign up for BostonGlobe.com digital subscription. Current print and digital subscribers are not eligible for the free trial.

Thanks & Welcome to Globe.com

You now have unlimited access for the next two weeks.

BostonGlobe.com complimentary digital access has been provided to you, without a subscription, for free starting today and ending in 14 days. After the free trial period, your free BostonGlobe.com digital access will stop immediately unless you sign up for BostonGlobe.com digital subscription. Current print and digital subscribers are not eligible for the free trial.