Bug 238672

Summary: char **environ should be declared in some system header (?)
Product: Base System Reporter: Yuri Victorovich <yuri>
Component: miscAssignee: freebsd-bugs (Nobody) <bugs>
Status: New ---    
Severity: Affects Only Me CC: tijl
Priority: ---    
Version: CURRENT   
Hardware: Any   
OS: Any   

Description Yuri Victorovich freebsd_committer 2019-06-17 22:16:28 UTC
Currently the man man page doesn't mention any header to include for 'environ':
>      environ — user environment
>      extern char **environ;

Shouldn't there be a header where it is declared?
Comment 1 Tijl Coosemans freebsd_committer 2019-07-04 11:07:01 UTC
No, it "must be declared by the user if it is to be used directly," according to https://pubs.opengroup.org/onlinepubs/9699919799/functions/environ.html.  Perhaps the man page should make that more clear.