SAN DIEGO (AP) – Johnny Cueto threw a four-hitter and Hunter Pence hit a two-run homer, leading the San Francisco Giants to their sixth straight win with a 2-1 victory over the San Diego Padres on Wednesday night.

Cueto (6-1) struck out eight and walked two while allowing one run in his second complete game of the season – both coming against the Padres. He improved to 4-1 in his career vs. San Diego, including a shutout on April 26.

The Giants, whose six-game streak has come on the road, also improved to 5-0 against San Diego this season, and have won 13 of the last 16 contests between the teams.

Buster Posey led off the fourth with a walk from Drew Pomeranz (4-4), who hadn’t allowed a run in 18 consecutive innings, and Pence followed with a homer that just cleared the right-field wall.

San Diego struck first when Brett Wallace doubled in the second and scored on a two-run single by Alexei Ramirez. Cueto went on to retire 15 of the next 16 batters he faced.

The Padres did not advance a runner past first base against Cueto after the second inning.

Pomeranz gave up two runs and four hits over six innings. He walked two and struck out five. The two runs were the first Pomeranz has allowed at Petco Park this season in three starts.

TRAINER’S ROOM:

Padres: IF Yangervis Solarte (hamstring) is on a rehab assignment and making progress. … RHP Tyson Ross (shoulder) has not resumed throwing since going on the disabled list after making one start on opening day.

UP NEXT:

Giants: RHP Jeff Samardzija (5-2, 2.88) looks to follow a solid outing in his last appearance in which he allowed one run over eight innings at Arizona.

Padres: RHP James Shields (2-5, 3.12) starts Thursday night. He had his best outing of the season in his last start, when he tossed seven scoreless innings at Milwaukee.