[llvm-bugs] [Bug 40729] New: Memory leak complain for putenv
via llvm-bugs
llvm-bugs at lists.llvm.org
Thu Feb 14 06:15:55 PST 2019
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: dcoughlin at apple.com
Reporter: pmatos at linki.tools
CC: dcoughlin at apple.com, llvm-bugs at 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.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20190214/2466361a/attachment.html>
More information about the llvm-bugs
mailing list