r114302: New warning introduced

Mark Shinwell shinwell@codesourcery.com
Fri Jun 2 08:58:00 GMT 2006


Jan-Benedict Glaw wrote:
> On Thu, 2006-06-01 10:30:54 -0000, shinwell@gcc.gnu.org <shinwell@gcc.gnu.org> wrote:
>> Author: shinwell
>> Date: Thu Jun  1 10:30:51 2006
>> New Revision: 114302
>>
>> URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=114302
>> libiberty:
>> 	* pex-unix.c: Add environment parameter to pex_unix_exec_child.
>> 	(pex_unix_exec_child): Pass environment to child process.
> 
> gcc -c -DHAVE_CONFIG_H -g -O2 -I. -I/tmp/build-temp-vax-linux-uclibc/src/binutils/libiberty/../include  -W -Wall -pedantic -Wwrite-strings -Wstrict-prototypes /tmp/build-temp-vax-linux-uclibc/src/binutils/libiberty/pex-unix.c -o pex-unix.o
> /tmp/build-temp-vax-linux-uclibc/src/binutils/libiberty/pex-unix.c: In function #pex_unix_exec_child#:
> /tmp/build-temp-vax-linux-uclibc/src/binutils/libiberty/pex-unix.c:418: warning: assignment discards qualifiers from pointer target type

My apologies.  The following patch should fix this, but assumes that
the pointers in environ will never be mutated.  Is this OK, or not?

Mark

--

libiberty/ChangeLog:

2006-06-02  Mark Shinwell  <shinwell@codesourcery.com>

         * pex-unix.c: Insert cast when assigning to environ.
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: environ.patch
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20060602/3308ce09/attachment.ksh>


More information about the Gcc-patches mailing list