https://bugs.llvm.org/show_bug.cgi?id=40729

            Bug ID: 40729
           Summary: Memory leak complain for putenv
           Product: clang
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Static Analyzer
          Assignee: dcough...@apple.com
          Reporter: pmatos@linki.tools
                CC: dcough...@apple.com, llvm-bugs@lists.llvm.org

The static analyzer complains about a possible memory leak for a buffer passed
into putenv, however a buffer for putenv (POSIX) should not be freed as it
becomes part of the environment.

>From the docs:
       The string pointed to by string becomes
       part of the environment, so altering  the  string  changes
       the environment.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to