7 SecKeychainItemFreeContent(ptr, &length);
8 // warn: trying to free data which has not been allocated
12 unsigned int *ptr = 0;
17 SecKeychainItemCopyContent(2, ptr, ptr, length, outData);
18 // warn: data is not released
22 unsigned int *ptr = 0;
27 SecKeychainItemCopyContent(2, ptr, ptr, length, &outData);
29 SecKeychainItemFreeContent(ptr, outData);
30 // warn: only call free if a non-NULL buffer was returned
34 unsigned int *ptr = 0;
39 SecKeychainItemCopyContent(2, ptr, ptr, length, &outData);
41 st = SecKeychainItemCopyContent(2, ptr, ptr, length, &outData);
42 // warn: release data before another call to the allocator
45 SecKeychainItemFreeContent(ptr, outData);
49 SecKeychainItemRef itemRef = 0;
50 SecKeychainAttributeInfo *info = 0;
51 SecItemClass *itemClass = 0;
52 SecKeychainAttributeList *attrList = 0;
57 SecKeychainItemCopyAttributesAndData(itemRef, info,
61 SecKeychainItemFreeContent(attrList, outData);
62 // warn: deallocator doesn't match the allocator