How to print int* (int pointer) and unsigned int* in log using NSLog?
- (int) doSomethingWith:(unsigned int)Msg withWparam:(unsigned int*)wParam withParameter:(int *) lParam
{
NSLog(@"MSg:%d wParam:%u lParam:%u",Msg,wParam,lParam);
//not working
return 1;
}
Warning: Format specifies type 'unsigned int' but the argument has type 'unsigned int *'
Use
%dforint. And the parameters are pointers, so use*to access the values pointed to.