I want to hook methods of class MPIncomingPhoneCallController
in iOS 5 to do something when a call comes. I use
Class _$MPIncomingPhoneCallController = objc_getClass("MPIncomingPhoneCallController");
MSHookMessage(_$MPIncomingPhoneCallController,
@selector(updateLCDWithName:label:breakPoint:),
(IMP) &Hook_LCD,
"pre_");
to hook updateLCDWithName:label:breakPoint:
, but it failed.
How can I do this?