Mercurial > hg > CbC > CbC_gcc
comparison gcc/config/i386/host-mingw32.c @ 145:1830386684a0
gcc-9.2.0
author | anatofuz |
---|---|
date | Thu, 13 Feb 2020 11:34:05 +0900 |
parents | 84e7813d76e9 |
children |
comparison
equal
deleted
inserted
replaced
131:84e7813d76e9 | 145:1830386684a0 |
---|---|
1 /* mingw32 host-specific hook definitions. | 1 /* mingw32 host-specific hook definitions. |
2 Copyright (C) 2004-2018 Free Software Foundation, Inc. | 2 Copyright (C) 2004-2020 Free Software Foundation, Inc. |
3 | 3 |
4 This file is part of GCC. | 4 This file is part of GCC. |
5 | 5 |
6 GCC is free software; you can redistribute it and/or modify it | 6 GCC is free software; you can redistribute it and/or modify it |
7 under the terms of the GNU General Public License as published | 7 under the terms of the GNU General Public License as published |
155 | 155 |
156 | 156 |
157 /* Determine the version of Windows we are running on and use a | 157 /* Determine the version of Windows we are running on and use a |
158 uniquely-named local object if running > 4. */ | 158 uniquely-named local object if running > 4. */ |
159 GetVersionEx (&version_info); | 159 GetVersionEx (&version_info); |
160 | |
161 char local_object_name[sizeof (OBJECT_NAME_FMT) + sizeof (DWORD) * 2]; | |
160 if (version_info.dwMajorVersion > 4) | 162 if (version_info.dwMajorVersion > 4) |
161 { | 163 { |
162 char local_object_name [sizeof (OBJECT_NAME_FMT) | |
163 + sizeof (DWORD) * 2]; | |
164 snprintf (local_object_name, sizeof (local_object_name), | 164 snprintf (local_object_name, sizeof (local_object_name), |
165 OBJECT_NAME_FMT "%lx", GetCurrentProcessId()); | 165 OBJECT_NAME_FMT "%lx", GetCurrentProcessId()); |
166 object_name = local_object_name; | 166 object_name = local_object_name; |
167 } | 167 } |
168 mmap_handle = CreateFileMappingA ((HANDLE) _get_osfhandle (fd), NULL, | 168 mmap_handle = CreateFileMappingA ((HANDLE) _get_osfhandle (fd), NULL, |