Re: RFC Abolish Narrow Margins
| From: | Zeev Suraski | Date: | Thu, 31 Jan 2019 16:20:42 +0000 |
| Subject: | Re: RFC Abolish Narrow Margins | ||
| References: | 1 2 3 4 5 6 7 8 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-103931@lists.php.net to get a copy of this message | ||
On Thu, Jan 31, 2019 at 6:09 PM Dmitry Stogov <dmitry@zend.com> wrote:
> The fact that FFI may leak, is because it uses "unmanaged memory" (like
> in real C). PHP reference counting and GC just can't handle all the
> cases. It's impossible to automatically know what to do with C pointer,
> when we get it from function or another structure. In this case
> programmer have to care about freeing the pointer themselves (like in C).
>
> This obviously doesn't count as 'leaks'. If it did, we could say that the
Zend Extension API leaks, as it's completely up to the developer to handle
memory management.
Joe - if that's your concern, I think it's fair to say it's invalid and you
have nothing to worry about.
Zeev