全部,当框架调用 objc_retain 时,将引发 EXC_BAD_ACCESS 异常。任何追踪问题的帮助或提示将不胜感激。让我知道是否应该提供更多代码。
问题领域:
- (SCUuidNode*)addUUIDNode:(NSString*)uuid
{
const char *uuidCStr = [uuid cStringUsingEncoding:NSASCIIStringEncoding];
SCUuidNode *uuidNode = [[SCUuidNode alloc] initWithNode:create_uuid_node(uuidCStr)];
composite_node_append_child((Node*)[self node], [uuidNode node]);
return uuidNode; # Exception is being thrown right around here.
}
...
Composite *paymentNode = [SCCompositeNode createPriceNode:^(SCCompositeNode *cnode) {
SCUuidNode *uuidNode = [cnode addUUIDNode:buyerDeviceId];
SCIntNode *buyerIdNode = [cnode addIntNode:[buyerUserId integerValue]];
}];