...
A programmer should never try to modify the value returned by the getenv() function. Because the pointer might be used by some other program. If it's necessary to manipulate the return value of getenv(). None
None-Compliant Code Example
Code Block |
---|
(Insert code here)
|
...
int foo()
{
char *env;
env = getenv("TEST_ENV");
env[0] = 'a';
/*do some more things*/
return 0;
}
|
Compliant Code Solution
Code Block |
---|
(insert code here) |