* Use __environ instead of environ on platforms where it exists.
git-svn-id: svn://svn.zoy.org/elk/trunk@206 55e467fa-43c5-0310-a8a2-de718669efc6
This commit is contained in:
		
							parent
							
								
									2b27088412
								
							
						
					
					
						commit
						25c92f739b
					
				| 
						 | 
				
			
			@ -42,7 +42,11 @@
 | 
			
		|||
#if defined(__APPLE__)
 | 
			
		||||
#   include <crt_externs.h>
 | 
			
		||||
#   define environ (* _NSGetEnviron())
 | 
			
		||||
#elif !defined(ENVIRON_IN_UNISTD_H)
 | 
			
		||||
#elif defined(__ENVIRON_IN_UNISTD_H)
 | 
			
		||||
#   define environ __environ
 | 
			
		||||
#elif defined(ENVIRON_IN_UNISTD_H)
 | 
			
		||||
/* Nothing to do */
 | 
			
		||||
#else
 | 
			
		||||
/* "extern" in front of the next declaration causes the Ultrix 4.2 linker
 | 
			
		||||
 * to fail, but omitting it no longer works with modern C compilers: */
 | 
			
		||||
extern char **environ;
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue