Re: [PATCH] Fix out-of-bouds access (src/common/wchar.c)
От | Daniel Gustafsson |
---|---|
Тема | Re: [PATCH] Fix out-of-bouds access (src/common/wchar.c) |
Дата | |
Msg-id | 13854846-62F4-4F5C-B00A-9691FCBC93ED@yesql.se обсуждение исходный текст |
Ответ на | Re: [PATCH] Fix out-of-bouds access (src/common/wchar.c) (Tom Lane <tgl@sss.pgh.pa.us>) |
Список | pgsql-hackers |
> On 17 Feb 2022, at 16:05, Tom Lane <tgl@sss.pgh.pa.us> wrote: > > Daniel Gustafsson <daniel@yesql.se> writes: >> Question remains though, should src/interfaces/ecpg/test/sql/sqlda.pgc really >> be using WIN32 and not _WIN32, or doesn't it matter? (or does it only matter >> for consistency?) WIN32 and _WIN32 aren't very informative searchterms to use >> for finding more information. > > I find this in src/include/port/win32.h: > > /* > * We always rely on the WIN32 macro being set by our build system, > * but _WIN32 is the compiler pre-defined macro. So make sure we define > * WIN32 whenever _WIN32 is set, to facilitate standalone building. > */ > #if defined(_WIN32) && !defined(WIN32) > #define WIN32 > #endif > > So for most of our code it shouldn't matter. However, I'm not sure > that the ECPG test cases include our port.h --- they probably shouldn't > if they're to reflect actual use-cases. [ pokes around... ] See > 517bf2d91 which added this code. Judging by the info in the Stack Overflow post and the commit message for 517bf2d91 it's seems perfectly correct to use _WIN32 in the ECPG test. Thanks! -- Daniel Gustafsson https://vmware.com/
В списке pgsql-hackers по дате отправления: