mirror of
https://github.com/unicode-org/icu.git
synced 2025-04-13 08:53:20 +00:00
ICU-11689 remove ICU-231 patch for VS2015 ufile.c
X-SVN-Rev: 37704
This commit is contained in:
parent
5c9e64e2d4
commit
f70eb29726
1 changed files with 14 additions and 2 deletions
|
@ -1,7 +1,7 @@
|
|||
/*
|
||||
******************************************************************************
|
||||
*
|
||||
* Copyright (C) 1998-2014, International Business Machines
|
||||
* Copyright (C) 1998-2015, International Business Machines
|
||||
* Corporation and others. All Rights Reserved.
|
||||
*
|
||||
******************************************************************************
|
||||
|
@ -63,7 +63,19 @@ finit_owner(FILE *f,
|
|||
uprv_memset(result, 0, sizeof(UFILE));
|
||||
result->fFileno = fileno(f);
|
||||
|
||||
#if U_PLATFORM_USES_ONLY_WIN32_API
|
||||
#if U_PLATFORM_USES_ONLY_WIN32_API && _MSC_VER < 1900
|
||||
/*
|
||||
* Below is a very old workaround (ICU ticket:231).
|
||||
*
|
||||
* Previously, 'FILE*' from inside and outside ICU's DLL
|
||||
* were different, because they pointed into local copies
|
||||
* of the io block. At least by VS 2015 the implementation
|
||||
* is something like:
|
||||
* stdio = _acrt_iob_func(0)
|
||||
* .. which is a function call, so should return the same pointer
|
||||
* regardless of call site.
|
||||
* As of _MSC_VER 1900 this patch is retired, at 16 years old.
|
||||
*/
|
||||
if (0 <= result->fFileno && result->fFileno <= 2) {
|
||||
/* stdin, stdout and stderr need to be special cased for Windows 98 */
|
||||
#if _MSC_VER >= 1400
|
||||
|
|
Loading…
Add table
Reference in a new issue