mirror of
https://github.com/9fans/plan9port.git
synced 2025-01-12 11:10:07 +00:00
lib9: putenv wraps POSIX setenv, not legacy putenv
POSIX setenv does everything that p9putenv's body, so just delegate to that. Signed-off-by: Dan Cross <cross@gajendra.net>
This commit is contained in:
parent
0be57355f9
commit
3ef80ba5f5
1 changed files with 1 additions and 7 deletions
|
@ -16,11 +16,5 @@ p9getenv(char *s)
|
|||
int
|
||||
p9putenv(char *s, char *v)
|
||||
{
|
||||
char *t;
|
||||
|
||||
t = smprint("%s=%s", s, v);
|
||||
if(t == nil)
|
||||
return -1;
|
||||
putenv(t);
|
||||
return 0;
|
||||
return setenv(s, v, 1);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue