Defending champion Borna Coric survived a major scare in the second round of the Halle Open.

The Croatian fourth seed won 7-6 (7-4) 5-7 7-6 (7-4) against Portuguese qualifier Joao Sousa to secure a quarter-final place.

Coric, who caused a major upset when beating Roger Federer in last year's final of this grass-court event, will next play Frenchman Pierre-Hugues Herbert, a 2-6 7-6 (7-2) 6-4 winner against Ukrainian qualifier Sergiy Stakhovsky.

Belgian David Goffin fended off Moldovan Radu Albot 4-6 6-4 6-3, and on a day of tight matches, Russian third seed Karen Khachanov defeated Germany's Jan-Lennard Struff 6-3 3-6 6-4.

Swiss top seed Federer resumes his Halle campaign on Thursday with a tricky assignment against Frenchman Jo-Wilfried Tsonga.