|
Boost : |
From: larsbj_at_[hidden]
Date: 2002-01-23 17:00:44
"Fernando Cacciola" <fcacciola_at_[hidden]> writes:
>> Are there systems that do not have the equivalent of getenv and
>> putenv?
>>
>> An super simple implementation on most unices could result in (f.ex.):
>>
>> envir_iterator env(environ);
>> envir_iterator end;
>> for (; env != end; ++env) {
>> pair<string, string> p = *env;
>> }
>>
>> Or do you want to avoid using the system environment?
>>
| This look good, but I have no idea how to implement that in terms of
| 'getenv'...
| How do you walk through all enviroment variables with it?
I should not have mentioned getenv,putenv... completly misleading.
On a lot of unix systems this is present:
extern char **environ;
and holds the whole environment forthe running process.
(and ends with a NULL pointer)
I have no idea if something similar exist on win32.
-- Lgb
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk