Inter started well as Croatian forward Perisic bulleted a header into the net in the 12th minute to give the title chasers the lead.
After Edin Dzeko was fouled in the 39th minute, Martinez was presented with the perfect opportunity to make it two from the spot, with the Argentine striker finding the net but only from the rebound after his penalty had been tipped on to the post.
Udinese did not give in after the break, and the pressure told as Ignacio Pussetto converted from close range to give his side hope with 18 minutes to play.
Inter survived further worrying moments in the latter stages in Udine, but held on to move on to 75 points from 35 matches played, two behind Milan after their victory over Fiorentina on Sunday. Udinese stay 12th on 43 points.