This is true not only in San Francisco, but with all 30 major-league teams: If the No. 5 starter struggles out of the gate, the fans want his head and start pleading for alternatives.

Ryan Vogelsong

San Francisco Giants’ Ryan Vogelsong works against the Cleveland Indians in the first inning of a baseball game, Sunday, April 27, 2014, in San Francisco. (AP Photo/Ben Margot)

Many Giants fans wanted Ryan Vogelsong out after he pitched to a 7.71 ERA over his first five starts. Some of those fans were probably behind the Giants dugout giving Vogelsong a standing ovation after he walked off the field, seven shutout innings in hand.

Vogelsong knows the pitfalls of being that struggling No. 5 starter.

“I’ve been in that situation a few times,” he said after Sunday’s 4-1 victory, adding it would be foolish to look over his shoulder.

“When it’s time to pitch the game, you’ve got to pitch the game,” he said.

It’s not just fans. Surely general manager Brian Sabean and manager Bruce Bochy at some point would have to consider replacing Vogelsong with Yusmeiro Petit if Vogelsong continued to struggle. On Thursday, Sabean said on his radio show that he usually begins that analysis after six starts. This was Vogelsong’s fifth, and he’s had two good ones in the past three.

The bad one was at Coors Field on Monday night, when he lasted 1 1/3 innings and allowed five runs. On Sunday, he allowed a game-opening single by Michael Bourn and walked Jason Kipnis with one out. He admitted that Denver crossed his mind.

“After the last game it was stuck in the back of my mind for a second,” Vogelsong said. ” ‘Not again.’ I tried to focus especially on making good pitches, and I made some.”

Carlos Santana flied out to deep right and Michael Brantley grounded out.

Vogelsong eventually finished seven shutout innings and retired his final 12 hitters.

He did not get his first win, though. That prospect disappeared four pitches into the eighth inning. Yan Gomes, the only right-handed hitter in Cleveland’s lineup, homered off Santiago Casilla to tie the game 1-1. Casilla had allowed one earned run in 2014 before that.

XXXXXXXXXX

My game story and Giants Beat for Monday’s paper will get into Vogelsong a bit more (as well as the Brandon Hicks walkoff homer, obviously). The Beat also will delve into Brandon Belt’s lost weekend: 0-for-12 with nine strikeouts. Manager Bruce Bochy joked after the game that Belt’s bat must have been manufactured by the “Chasm” bat company because of the big hole in it.

The troubling aspect is the way Belt is getting beaten on fastballs over the plate, not in on his hands.

He’s been through this before. He had a four-strikeout game and even a five-strikeout game last year.

We didn’t see Belt in the clubhouse after the game, but Brandon Crawford said Belt was in good spirits because of the win.

“He’ll be all right,” Crawford said. “We’re not worried about him.”

XXXXXXXXXX

While Belt is falling into bad habits, other slumping Giants slowly but surely are coming out of it.

Hunter Pence already has. He has raised his average in six games from .181 to .253 .

Buster Posey had been hitless in 24 consecutive at-bats against right-handed pitchers before he homered against one Saturday. On Sunday, he had two singles against righties, one each off Danny Salazar and Cody Allen. The latter started the winning rally in the ninth.

Even Pablo Sandoval, whose average stands at .180, has looked better the past two games. He had his third multihit game of the year Sunday with an opposite-field double and a single to center. That single was a big deal, his first hit in 43 at-bats this year in a two-strike count.

Sandoval said the double was a good sign because it came on a tough pitch. As for the single, he said he has worked hard with batting coach Hensley Meulens on two-strike approach. It’s really simple stuff — shorten your swing, think middle of the field — but Sandoval admitted it’s tough sometimes to think that way when you’re trying too hard to bust out.

XXXXXXXXXX

Odds and ends:

I have to admit I don’t like writing about the Giants’ sellout streak because many games are only sold out in a bureaucratic sense, based on league definitions, while people can walk up to the ticket office five minutes before first pitch. But that’s true for all teams, so I’ll point out that the Giants set the National League record for consecutive “sellouts” with their 258th Sunday. The announced crowd was 41,530.

There’s some bad news in the minors. Mac Williamson, the Giants’ top outfield prospect, has been sent to extended-spring training with an elbow injury. He already had is expected assignment to Double-A Richmond, Va., delayed by a shoulder injury.

An interesting stat that seems incongruous: The Giants are 7-7 in their past 14 games despite having two or fewer hits with runners in scoring position in each game. They were 2-for-7 Sunday, Crawford’s RBI double int he fourth and Hicks’ walkoff homer in the ninth.

Twenty-five games into the season, Tim Hudson has half the rotation’s wins, three of six.

Barry Bonds was in the clubhouse before the game, not in any official capacity. “I think he’s moved up here,” Bochy said. “I think he’s going to pop in occasionally. With him moving into The City I’m sure he’s going to come by and say hello.”

The Giants have swept the Indians at AT&T Park twice in a row, after Cleveland swept them in its first visit to San Francisco in 2005.