[Lldb-commits] [PATCH] D18459: Fix FILE * leak in Python API

Francis Ricci via lldb-commits lldb-commits at lists.llvm.org
Fri Mar 25 09:12:02 PDT 2016


fjricci added a comment.

Would we want this overloaded method taking an int (fd) instead of a FILE* to be present in the API? Or hidden somehow? I'm new to swig, but it looks like python-extensions.swig includes some private extensions to the CommandReturnObject class already.

Overloading with an fd argument seems quite a bit more complex than doing what we do now but setting transfer_ownership in the underlying `CommandReturnObject::SetImmediateOutputFile()` call to true (which could probably be done either with a new swig extension or by changing the api). Do you think it's worth the added complexity?


http://reviews.llvm.org/D18459





More information about the lldb-commits mailing list