IOS Crash Report Skproductsrequest

Source: Internet
Author: User

About

-(void) Productsrequest: (skproductsrequest *) Request Didreceiveresponse: (Skproductsresponse *) response

The method does not respond or crashes directly.

First case:

In this class, call the

It is possible that the Skproductrequest object has been disposed.

The request is likely to take a few seconds to complete, and this may exceed the life cycle of the delegate object, so make sure that it is long enough as much as possible.

Set it to a global variable or property (Nonatomic, Strong).

second case :

Instead of using the IPA directly in this class, the new Helperipa class calls inside the purchase,

You need to implement a singleton in the helper class

+ (class name *) sharedpurchase {

Static Class name * _SHAREDP = nil;

Static dispatch_once_t Oncetoken;

Dispatch_once (&oncetoken, ^{

_SHAREDP = [[Class name alloc] init];

});

return _SHAREDP;

}

In arc mode, the helper class is called, and the Skproductrequest object is reclaimed directly by the system after the method is executed in parentheses.

IOS Crash Report Skproductsrequest

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.