Re: Fixing MSVC's inability to detect elog(ERROR) does not return

Поиск
Список
Период
Сортировка
От David Rowley
Тема Re: Fixing MSVC's inability to detect elog(ERROR) does not return
Дата
Msg-id CAApHDvrJ7ePYW8474s57Tk7BD4C2UZe6MkGrDSafz8V1XTdqSA@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Fixing MSVC's inability to detect elog(ERROR) does not return  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: Fixing MSVC's inability to detect elog(ERROR) does not return
Список pgsql-hackers
On Thu, 24 Jul 2025 at 12:27, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Hmmm ... but you did check that in fact we can remove such known-dead
> code and not get a warning now?

Yes. The patch has a small temporary adjustment to
BaseBackupGetTargetHandle() to comment out the return. It compiles for
me using Visual Studio 2022 without any warnings. If I remove the
macro change, I get:

[598/2255] Compiling C object
src/backend/postgres_lib.a.p/backup_basebackup_target.c.obj
src\backend\backup\basebackup_target.c(150) : warning C4715:
'BaseBackupGetTargetHandle': not all control paths return a value

David



В списке pgsql-hackers по дате отправления: