On 3 February 2014, ZyX <zyx....@gmail.com> wrote:
> There are some questions about memory: do I read correctly
> that not to leak memory you must keep track which
> environment variables you have set with putenv() and run
> `vim_free(&(getenv("VAR")[-STRLEN("VAR")-1]));` just before you are
> about to use putenv() or unsetenv() for such variables? It is also
> interesting whether you need to free() variables which were already
> there.
[...]

    No, it's unsafe to free() environment variables.  As far as I know
most libc implementations just leak a tiny bit of memory there.  It's
harmless, and you certainly aren't supposed to attempt to solve it.

    /lcd

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Raspunde prin e-mail lui