The putenv() in the FreeBSD 7.x is made posix-conforming, that means
that the function does not make the copy of the argument string for entering
it into the environment.

As consequence, gcc/ada/env.c, __gnat_setenv() function shall not call
free() on the malloc'ed string. Otherwise, memory of the environment
strings become corrupted. In particular, bootstrap cannot proceed because
gnat tools segfaults.


-- 
           Summary: putenv() is made posix-conformant on FreeBSD 7.x
           Product: gcc
           Version: 4.2.2
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: ada
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: kostikbel at ukr dot net
 GCC build triplet: i386-pc-freebsd7
  GCC host triplet: i386-pc-freebsd7
GCC target triplet: i386-pc-freebsd7


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33722

Reply via email to