Re: pg_read_file() with virtual files returns empty string
В списке pgsql-hackers по дате отправления:
| От | Tom Lane |
|---|---|
| Тема | Re: pg_read_file() with virtual files returns empty string |
| Дата | |
| Msg-id | 1194666.1593881544@sss.pgh.pa.us обсуждение |
| Ответ на | Re: pg_read_file() with virtual files returns empty string (Justin Pryzby <pryzby@telsasoft.com>) |
| Ответы |
Re: pg_read_file() with virtual files returns empty string
|
| Список | pgsql-hackers |
Justin Pryzby <pryzby@telsasoft.com> writes:
> But I noticed that cfbot is now populating with failures like:
> genfile.c: In function ‘read_binary_file’:
> genfile.c:192:5: error: ignoring return value of ‘fread’, declared with attribute warn_unused_result
[-Werror=unused-result]
> fread(rbuf, 1, 1, file);
> ^
Yeah, some of the pickier buildfarm members (eg spurfowl) are showing
that as a warning, too. Maybe make it like
if (fread(rbuf, 1, 1, file) != 0 || !feof(file))
ereport(ERROR,
Probably the feof test is redundant this way, but I'd be inclined to
leave it in anyhow.
regards, tom lane
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера