Roger Federer was tested by Filip Krajinovic before winning 6-2, 4-6, 6-4 in the first round of his hometown tournament Swiss Indoors on Tuesday.

The top-seeded Federer seemed in control after winning seven straight games to take the first set and lead by a break in the second.

Switzerland’s Roger Federer returns a ball to Serbia’s Filip Krajinovic during their first round match at the Swiss Indoors tennis tournament at the St. Jakobshalle in Basel, Switzerland, on Tuesday, Oct. 23, 2018. (Georgios Kefalas/ Keystone via AP)

The 35th-ranked Serb then broke Federer’s serve three times, including back-to-back to clinch the set and level the match.

Serbia’s Filip Krajinovic returns a ball to Switzerland’s Roger Federer during their first round match at the Swiss Indoors tennis tournament at the St. Jakobshalle in Basel, Switzerland, on Tuesday, Oct. 23, 2018. (Georgios Kefalas/ Keystone via AP)

Federer got the key break early in the deciding set and reeled off five straight points when facing three break chances in the sixth game. He clinched the win when Krajinovic sent a backhand long.

Switzerland’s Roger Federer returns a ball to Serbia’s Filip Krajinovic during their first round match at the Swiss Indoors tennis tournament at the St. Jakobshalle in Basel, Switzerland, on Tuesday, Oct. 23, 2018. (Georgios Kefalas/ Keystone via AP)

Federer next plays Jan-Lennard Struff. The 52nd-ranked German beat Australia’s John Millman, who eliminated Federer at the U.S. Open last month, 7-6 (3), 6-2.

Australia’s John Millman returns a ball to Germany’s Jan-Lennard Struff during their first round match at the Swiss Indoors tennis tournament at the St. Jakobshalle in Basel, Switzerland, on Tuesday, October 23, 2018. (Georgios Kefalas/Keystone via AP)

___

Germany’s Jan-Lennard Struff returns a ball to Australia’s John Millman during their first round match at the Swiss Indoors tennis tournament at the St. Jakobshalle in Basel, Switzerland, on Tuesday, October 23, 2018. (Georgios Kefalas/Keystone via AP)

Source: The Associated Press