[LLVMbugs] [Bug 21487] New: Incorrect detection of nil object

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Wed Nov 5 06:33:22 PST 2014


http://llvm.org/bugs/show_bug.cgi?id=21487

            Bug ID: 21487
           Summary: Incorrect detection of nil object
           Product: clang
           Version: 3.5
          Hardware: Macintosh
                OS: MacOS X
            Status: NEW
          Severity: normal
          Priority: P
         Component: Static Analyzer
          Assignee: kremenek at apple.com
          Reporter: jacobisrael at mail.usf.edu
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

Under NON-ARC

NSString *fileName = nil;

if(){
   if(){
      if(){
        fileName = [[NSString alloc] initWithString:iconfileName];
        // ....
      }
   }
}

if(fileName)
{
   //   ...
  [fileName release];
}

// Analyzer complains that fileName could be a potential memory leak

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20141105/7447d2f4/attachment.html>


More information about the llvm-bugs mailing list