diff options
| author | ocean <ocean@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2006-02-01 13:27:47 +0000 |
|---|---|---|
| committer | ocean <ocean@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2006-02-01 13:27:47 +0000 |
| commit | 6d31e151f62c25ecbe84567fda2865902190939d (patch) | |
| tree | a4b102d011c81fbcc9ac518c607121747a6b469c /hash.c | |
| parent | 6b822a4b44a16fb89366c3c5820c1bd8b1030398 (diff) | |
| download | ruby-6d31e151f62c25ecbe84567fda2865902190939d.tar.gz ruby-6d31e151f62c25ecbe84567fda2865902190939d.tar.xz ruby-6d31e151f62c25ecbe84567fda2865902190939d.zip | |
* configure.in, hash.c (ruby_setenv): use setenv(3) and unsetenv(3)
where they are supported. modifing environ variable seems to
segfault solaris 10. [ruby-core:7276] [ruby-dev:28270]
* ruby.c (set_arg0): if use setenv(3), environ space cannot be used
for altering argv[0].
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@9868 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'hash.c')
| -rw-r--r-- | hash.c | 4 |
1 files changed, 1 insertions, 3 deletions
@@ -196,8 +196,6 @@ rb_hash_foreach(VALUE hash, int (*func)(ANYARGS), VALUE farg) rb_ensure(hash_foreach_call, (VALUE)&arg, hash_foreach_ensure, hash); } -static VALUE hash_alloc(VALUE); - static VALUE hash_alloc(VALUE klass) { @@ -1690,7 +1688,7 @@ ruby_setenv(const char *name, const char *value) * RTL's environ global variable directly yet. */ SetEnvironmentVariable(name,value); -#elif defined __CYGWIN__ +#elif defined(HAVE_SETENV) && defined(HAVE_UNSETENV) #undef setenv #undef unsetenv if (value) |
