* dcrt0.cc (cygwin_atexit): Change preceeding comment to reflect
API version numbers. * external.cc (cygwin_internal): disable setting cxx_malloc on 64 bit. Add CW_FIXED_ATEXIT case. * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump. * include/sys/cygwin.h (cygwin_getinfo_types): Add CW_FIXED_ATEXIT. * lib/atexit.c (atexit): Test running Cygwin version by checking return value of cygwin_internal (CW_FIXED_ATEXIT).
This commit is contained in:
@@ -243,11 +243,13 @@ cygwin_internal (cygwin_getinfo_types t, ...)
|
||||
break;
|
||||
|
||||
case CW_USER_DATA:
|
||||
#ifndef __x86_64__
|
||||
/* This is a kludge to work around a version of _cygwin_common_crt0
|
||||
which overwrote the cxx_malloc field with the local DLL copy.
|
||||
Hilarity ensues if the DLL is not loaded like while the process
|
||||
is forking. */
|
||||
__cygwin_user_data.cxx_malloc = &default_cygwin_cxx_malloc;
|
||||
#endif
|
||||
res = (uintptr_t) &__cygwin_user_data;
|
||||
break;
|
||||
|
||||
@@ -673,6 +675,10 @@ cygwin_internal (cygwin_getinfo_types t, ...)
|
||||
}
|
||||
break;
|
||||
|
||||
case CW_FIXED_ATEXIT:
|
||||
res = 0;
|
||||
break;
|
||||
|
||||
default:
|
||||
set_errno (ENOSYS);
|
||||
}
|
||||
|
Reference in New Issue
Block a user