Re: signed short fd

Поиск
Список
Период
Сортировка
От pgsql@mohawksoft.com
Тема Re: signed short fd
Дата
Msg-id 16480.24.91.171.78.1110835522.squirrel@mail.mohawksoft.com
обсуждение исходный текст
Ответ на Re: signed short fd  (Andrew Dunstan <andrew@dunslane.net>)
Ответы Re: signed short fd  (Neil Conway <neilc@samurai.com>)
Re: signed short fd  (Abhijit Menon-Sen <ams@oryx.com>)
Список pgsql-hackers
> My copy of APUE says on page 49: "The file descriptor returned by open
> is the lowest numbered unused descriptor. This is used by some
> applications to open a new file on standard input, standard output, or
> standard error."

Yes, I'll restate my questions:

What is meant by "unused?" Is it read to mean that a higher number file is
*never* returned if there is a lower number that has been used and is now
available? Is that something we can 100% absolutely depend on. On All
curent and future platforms?

It is a stupid idea to truncate the upper bytes of an integer without good
reason. I can see LOTS of reasons why this will break something in the
future. The upper bits may be used to identify storage media or
characteristics.

My point is that the spec calls for an "int," PostgreSQL should use an int.

>
> Unless someone can show there's an actual problem this discussion seems
> quite pointless.
>

The point is that this *is* silly, but I am at a loss to understand why it
isn't a no-brainer to change. Why is there a fight over a trivial change
which will ensure that PostgreSQL aligns to the documented behavior of
"open()"



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

Предыдущее
От: Andrew Dunstan
Дата:
Сообщение: Re: signed short fd
Следующее
От: Neil Conway
Дата:
Сообщение: Re: signed short fd