getenv
function, which retrieves the value of a named environment variable. Both the name and value are character strings."Use getenv function! Don't use
getpwuid(getuid())->pw_dir
to access struct passwd
! getenv is a handy function to access environments variables like HOME and PWD.
No comments:
Post a Comment