diff options
author | hboehm <hboehm@138bc75d-0d04-0410-961f-82ee72b054a4> | 2003-10-03 18:43:06 +0000 |
---|---|---|
committer | hboehm <hboehm@138bc75d-0d04-0410-961f-82ee72b054a4> | 2003-10-03 18:43:06 +0000 |
commit | d30fdfb972fa8c97695e72fc0e939ace7d497e13 (patch) | |
tree | 24628e70256e7b26eb5d3ef1d7173ad25c32fea6 /boehm-gc/include | |
parent | b494d19353d5c7b9ef2f7edf4e9ef2efce33569f (diff) | |
download | gcc-d30fdfb972fa8c97695e72fc0e939ace7d497e13.tar.gz |
* configure.in: Remove NO_GETENV definition for win32.
* mach_dep.c (GC_generic_push_regs): Prevent tail call optimization.
* misc.c (GC_init_inner): Call GC_thr_init for win32.
(GC_set_warn_proc): Add assertion.
* win32_threads.c: Import 6.3alpha2 version.
* include/private/gc_priv.h: Add support for EMPTY_GETENV_RESULTS.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@72074 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'boehm-gc/include')
-rw-r--r-- | boehm-gc/include/private/gc_priv.h | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/boehm-gc/include/private/gc_priv.h b/boehm-gc/include/private/gc_priv.h index ffa398b308b..5e7625fb150 100644 --- a/boehm-gc/include/private/gc_priv.h +++ b/boehm-gc/include/private/gc_priv.h @@ -448,7 +448,19 @@ extern GC_warn_proc GC_current_warn_proc; /* Get environment entry */ #if !defined(NO_GETENV) -# define GETENV(name) getenv(name) +# if defined(EMPTY_GETENV_RESULTS) + /* Workaround for a reputed Wine bug. */ + static inline char * fixed_getenv(const char *name) + { + char * tmp = getenv(name); + if (tmp == 0 || strlen(tmp) == 0) + return 0; + return tmp; + } +# define GETENV(name) fixed_getenv(name) +# else +# define GETENV(name) getenv(name) +# endif #else # define GETENV(name) 0 #endif |