Commit
fe363de1647013c190ac3e9d25bb1d7d3fbe574d
by brice.goglincore+levelzero: Set ZES_ENABLE_SYSMAN via setenv instead of putenv
Setting `ZES_ENABLE_SYSMAN` via `putenv` placed a constant string
in the environ array which cannot be touched. If the user is
manipulating that environ array then touching this envar will
result in a segv.
- Instead of using `putenv` use `setenv` which will put a copy
of the constant string in the `environ` array allowing the
end user to manipulate that array as needed.
- Note that I could not find a `setenv` function for windows
so I left a comment and did not touch that code.
Signed-off-by: Joshua Hursey <jhursey@us.ibm.com>
Also change the putenv() inside topology-levelzero.c for consistency
and update some comments.
Signed-off-by: Brice Goglin <Brice.Goglin@inria.fr>