delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/2001/10/02/11:58:54

From: "Tim Van Holder" <tim DOT van DOT holder AT pandora DOT be>
To: <djgpp-workers AT delorie DOT com>
Subject: Re: putenv question
Date: Tue, 2 Oct 2001 17:57:32 +0200
Message-ID: <000301c14b5a$f2448080$d0f8e0d5@pandora.be>
MIME-Version: 1.0
X-Priority: 3 (Normal)
X-MSMail-Priority: Normal
X-Mailer: Microsoft Outlook, Build 10.0.2627
In-Reply-To: <200110021518.LAA17354@qnx.com>
Importance: Normal
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4807.1700
Reply-To: djgpp-workers AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp-workers AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

> Implementation should not make a copy of the string because this will
> violate the standard,  (but I may be wrong 8-).

Right - just noticed this myself:

The putenv() function shall use the string argument to set environment
variable values. The string argument should point to a string of the
form "name=value. The putenv() function shall make the value of the
environment variable name equal to value by altering an existing
variable
or creating a new one. In either case, the string pointed to by string
shall become part of the environment, so altering the string shall
change
the environment. The space used by string is no longer used once a new
string defining name is passed to putenv( ).

Looks like our putenv doesn't comply, and needs to be changed
to match this behaviour.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019