equal
deleted
inserted
replaced
585 # define __sigprocmask sigprocmask |
585 # define __sigprocmask sigprocmask |
586 # define __execve execve |
586 # define __execve execve |
587 # define __wait wait |
587 # define __wait wait |
588 # define __waitpid waitpid |
588 # define __waitpid waitpid |
589 # endif /* ! LINUX */ |
589 # endif /* ! LINUX */ |
590 extern char **environ; |
590 # ifndef __osx__ |
|
591 extern char **environ; |
|
592 # endif |
591 # endif |
593 # endif |
592 |
594 |
593 # define __sigprocmask sigprocmask |
595 # define __sigprocmask sigprocmask |
594 # define __execve execve |
596 # define __execve execve |
595 |
597 |
2887 aCommandPath := self encodePath:aCommandPathArg. |
2889 aCommandPath := self encodePath:aCommandPathArg. |
2888 |
2890 |
2889 %{ /* STACK: 16000 */ |
2891 %{ /* STACK: 16000 */ |
2890 char **argv; |
2892 char **argv; |
2891 int nargs, i, id; |
2893 int nargs, i, id; |
2892 OBJ arg; |
2894 OBJ arg; |
|
2895 #ifdef __osx__ |
|
2896 char **environ = _NSGetEnviron(); |
|
2897 #else |
2893 extern char **environ; |
2898 extern char **environ; |
|
2899 #endif |
2894 char **_env, **_nEnv; |
2900 char **_env, **_nEnv; |
2895 |
2901 |
2896 if (__isStringLike(aCommandPath) && |
2902 if (__isStringLike(aCommandPath) && |
2897 ((argArray == nil) || __isArrayLike(argArray)) && |
2903 ((argArray == nil) || __isArrayLike(argArray)) && |
2898 ((fdArray == nil) || __isArrayLike(fdArray)) |
2904 ((fdArray == nil) || __isArrayLike(fdArray)) |
6502 getEnvironment |
6508 getEnvironment |
6503 "answer the whole environment as a Dictionary" |
6509 "answer the whole environment as a Dictionary" |
6504 |
6510 |
6505 |resultArray error dict sz "{ Class: SmallInteger }"| |
6511 |resultArray error dict sz "{ Class: SmallInteger }"| |
6506 |
6512 |
6507 %{ |
6513 %{ |
6508 |
6514 #ifdef __osx__ |
|
6515 char **environ = _NSGetEnviron(); |
|
6516 #else |
6509 extern char **environ; |
6517 extern char **environ; |
|
6518 #endif |
6510 char **env; |
6519 char **env; |
6511 int nEnv = 0; |
6520 int nEnv = 0; |
6512 |
6521 |
6513 /* |
6522 /* |
6514 * get the size of the environment |
6523 * get the size of the environment |
13441 ! ! |
13450 ! ! |
13442 |
13451 |
13443 !UnixOperatingSystem class methodsFor:'documentation'! |
13452 !UnixOperatingSystem class methodsFor:'documentation'! |
13444 |
13453 |
13445 version |
13454 version |
13446 ^ '$Header: /cvs/stx/stx/libbasic/UnixOperatingSystem.st,v 1.301 2013-01-17 22:37:55 cg Exp $' |
13455 ^ '$Header: /cvs/stx/stx/libbasic/UnixOperatingSystem.st,v 1.302 2013-01-23 18:05:37 cg Exp $' |
13447 ! |
13456 ! |
13448 |
13457 |
13449 version_CVS |
13458 version_CVS |
13450 ^ '$Header: /cvs/stx/stx/libbasic/UnixOperatingSystem.st,v 1.301 2013-01-17 22:37:55 cg Exp $' |
13459 ^ '$Header: /cvs/stx/stx/libbasic/UnixOperatingSystem.st,v 1.302 2013-01-23 18:05:37 cg Exp $' |
13451 ! ! |
13460 ! ! |
13452 |
13461 |
13453 |
13462 |
13454 UnixOperatingSystem initialize! |
13463 UnixOperatingSystem initialize! |
13455 UnixOperatingSystem::FileDescriptorHandle initialize! |
13464 UnixOperatingSystem::FileDescriptorHandle initialize! |