tags:

views:

101

answers:

0

HI all,

      When I tried to access the IM list of the contact using the following code:

ABMultiValueRef IMS = ABRecordCopyValue(record, kABPersonInstantMessageProperty);
if(IMS)
{
    int IMSCount = ABMultiValueGetCount(IMS);
    for(int iIM =0; iIM < IMSCount; ++iIM)
            {

              CFDictionaryRef dict  = ABMultiValueCopyValueAtIndex(IMS, iIM);
             }
    }

, I am getting the bad access in the device. The following is the stack trace of the bad access.

0 0x32d679a0 in forwarding

1 0x32d5e840 in forwarding_prep_0_

2 0x32d83d70 in CFRetain

3 0x33e63154 in ABCCopyDictionaryWithTypes

4 0x33e6cb50 in ABMultiValueCopyValueAtIndex

Any help will be greatly appreciated ....

Best Regards, Mohammed Sadiq.