ref: 004f6f57af8b5bbc2ff07b0f8fce148ba4c1c24d
dir: /libnpe/setenv.c/
#include <u.h> #include <libc.h> int setenv(char *name, char *value, int overwrite) { char *s; if(overwrite == 0 && (s = getenv(name)) != nil){ free(s); return 0; } return putenv(name, value); }