Hendricks (4-4) allowed five hits walked one and struck out six.
Marlins starter Mat Latos (3-6) pitched well in the loss. He allowed one run, one hit and two walks in seven innings.
Latos' only shaky inning was the first. He walked Coghlan, gave up a single to Kris Bryant as Coghlan advanced to third. Later in the inning, Latos' wild pitch bounced into the stands, allowing Coghlan to score to put the Cubs ahead 1-0.
Latos then retired 20 of the next 22 batters, and the Cubs didn't get another hit until the eighth inning when Chris Denorfia led off the inning with a pinch-hit double off reliever Carter Capps. Denorfia scored on Coghlan's single.
Pedro Strop struck out one in the eighth and Jason Motte earned his fourth save.