Sergio Romo had a one-run lead to protect in the ninth inning, courtesy of Tyler Colvin’s tiebreaking double in the top half, and the Giants’ closer had converted 15 of 16 save chances this season.

But Romo’s stuff has been backing up in recent appearances. And the Rockies held his nose to it.

Nolan Arenado fouled off two hittable sliders, and with the Giants a strike away from victory, he didn’t miss a third. Arenado’s line drive that hit near the top the left field fence for a two-run, walk-off double and the Giants lost 5-4 to the Colorado Rockies at Coors Field on Tuesday.

Starting pitching reportMadison Bumgarner set a franchise record by recording an 18th consecutive road start in which he allowed no more than three earned runs.

Not that he was grabbing handfuls of confetti.

It was a tough and sometimes maddening night for Bumgarner, who appeared visibly frustrated by the strike zone, the replay procedure and the Rockies dugout, at different junctures in his six innings.

The Rockies scored their first run in the fourth after left fielder Tyler Colvin had Troy Tulowitzki’s double deflect off his glove for a double, then Wilin Rosario extended his arms and doubled to right field on a backdoor curveball.

Bumgarner stranded two runners in the fifth, when he threw a 1-1 slider that hit Tulowitzki in the meaty part of his calf.

Then came an eventful sixth inning. With the Rockies trailing 3-1, Nolan Arenado singled up the middle on a pitch that was an inch or two off the ground -- and the world became more unfair for Bumgarner after that. Perhaps stinging from the curve that Rosario hit off him for an RBI double in the previous at-bat, Bumgarner tried a first-pitch cutter and the Rockies’ powerful catcher crushed it three-quarters of the way up the left field seats for a tying, two-run home run.

Bumgarner didn’t appear to appreciate the strike zone on a 3-2 pitch that Drew Stubbs took for a walk. So Bumgarner took an aggressive tack when he fielded D.J. LeMahieu’s bunt, whirling and firing to second base. His throw surprised Stubbs, who coasted into second base standing up as Brandon Crawford received the throw. Stubbs was called safe and the Giants challenged. Although one view appeared conclusive, another view made it difficult to see when Crawford’s heel hit the base. The call stood and Bumgarner flailed his arms.

But disaster was averted when pitcher Franklin Morales struck out trying to sacrifice, then Bumgarner speared Brandon Barnes’ line drive and threw to first base to double off LeMahieu.

Bumgarner had thrown 100 pitches and worked through a couple of stressful innings, so his night was over on the mound. But with the Giants down to just tow healthy bodies on the bench, he batted for himself in the seventh. Left-hander Rex Brothers hit Bumgarner in the lower legs with an 0-2 pitch; Bumgarner had words with Rosario, then had more with the Rockies bullpen as he made a “come on” gesture with his hands as he jogged to first base.

If all that wasn’t enough, Bumgarner also swung 3-0 (!!) before striking out in the fifth inning.

Bullpen reportJean Machi struck out two in a scoreless seventh and Santiago Casilla proved capable in the eighth.

Romo blew just his second save in 17 opportunities. He issued a leadoff walk to Justin Morneau, survived a fly out to the warning track in right field from Michael Cuddyer and then had to go through the dangerous heart of Colorado’s order.

Tulowitzki grounded into a forceout but Carlos Gonzalez looped a single into shallow center field to put runners at the corners with two out. Nolan Arenado fouled off two hittable sliders before lining the third one off the left field fence.

At the plateMorales threw strikes with a big breaking ball, but the Giants benefited from a replay challenge while finally getting to him for three runs in the fifth inning.

Crawford singled up the middle and Colvin followed with a squeaker of a line drive that was called foul after it landed near the left field line. The Giants challenged the call and replays appeared to show that chalk or white paint kicked up as the ball struck the very outside edge of the line. The call was overturned, Colvin had a double and Crawford was ordered to third base.

Bumgarner struck out after taking a good if unexpected rip at a 3-0 pitch, leaving the Giants in need of some two-out magic. Gregor Blanco provided it, somehow keeping an outside pitch from going off the end of the bat while hitting a two-strike, two-run triple over the head of Stubbs in center field.

Colvin came through with his biggest hit of the night in the ninth after Brandon Hicks singled off LaTroy Hawkins. With two out, Colvin stayed through an outside pitch and dumped it down the left field line – no replays needed this time – and Hicks scored from first base without a throw.

In fieldMichael Morse’s inexperience at first base showed in the third inning, when he charged a bunt that Bumgarner fielded and got caught in between when the pitcher fired to first base. Morse crouched down but stuck out his glove and caught the ball, perhaps unsure if second baseman Brandon Hicks was covering behind him. Hicks was, and it would’ve been an out if Morse had let the throw go through.

Crawford bailed everyone out, charging Cuddyer’s short-hop grounder while being screened by a runner to field a tough play and throw for the third out, stranding two runners in scoring position.

Colvin couldn’t catch Tulowitzki’s double in the fourth, but he took a good first step and made a running catch of Tulo’s scalded line drive in the seventh.

Hicks made the Giants’ only error of the night when he couldn’t come up with a spinning, one-hop grounder in the fourth.

Up nextThe Giants and Rockies continue their three-game series at Coors Field on Wednesday. Matt Cain (1-3, 4.33) takes the mound against right-hander Jhoulys Chacin (0-2, 4.76). First pitch is scheduled for 5:40 p.m. PDT.