The Croatian, seeded two, was given a real fight by the Italian in the second set after Galvani had succumbed meekly in the first.
"Like in Beijing, this was a very, very tough match," said the 22-year-old Ancic, who beat the 108th-ranked Galvani in the second round of the China Open two weeks ago.
"He has a great return of serve. I came in really aggressive in the second and took my chances," said the big-serving Ancic, who finished runner-up to Cypriot Marcus Baghdatis in China following his return from a two-month injury break.
The knee injury marred what was otherwise a stellar season in which he broke into the world's top 10 for the first time.
"It (my fitness) is coming back, but of course match situations are always different from practice," Ancic said. "So far so good and I am looking forward to the next match."
Ancic will next meet Austrian Stefan Koubek on Friday after he beat unseeded Frenchman Nicholas Devilder 7-5 6-3.
Russian Dmitry Tursunov, the fourth seed, quelled the spirited challenge of Denmark's Kristian Pless 6-7 6-3 6-4 to also move into the quarter-finals.
Unseeded Pless, ranked 109 in the world, squeezed through the first set before Tursunov, who took Russia into the Davis Cup final with a five-set marathon victory over American Andy Roddick last week, turned it around.
Tursunov will next meet Great Britain's James Auckland, ranked 414th in the world, who got past eighth seed South African Wesley Moodie 7-6 7-6.
"I wasn't moving so well, but if it was enough to win that's good," Tursunov said.
Third seed Czech Tomas Berdych laboured past German Simon Greul 7-6 6-4 in the second round. Berdych will take on sixth seeded German Bjorn Phau in the quarter-finals.