Search code examples
objective-ciosmemory-leaksretaincount

ios potential leak how to solve?


I've analyzed my project: and this is the result: enter image description here

what means and how can I solve this?


Solution

  • You should release pdfURL after you have used it to create pdf.

    Try...

    CGPDFDocumentRef pdf = CGPDFDocumentCreateWithURL(pdfURL);
    CFRelease(pdfURL);