Re: IPV4 addresses on IPV6 machines in pg_hba.conf

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: IPV4 addresses on IPV6 machines in pg_hba.conf
Дата
Msg-id 25855.1062803731@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: IPV4 addresses on IPV6 machines in pg_hba.conf  (Andreas Pflug <pgadmin@pse-consulting.de>)
Ответы Re: IPV4 addresses on IPV6 machines in pg_hba.conf
Список pgsql-patches
Andreas Pflug <pgadmin@pse-consulting.de> writes:
> are you sure it's not just for beauty's sake?

What I didn't like about your last patch was the close coupling of the
CIDR/netmask processing to the v4-to-v6 conversion; as Andrew pointed
out, you were hacking into hba.c functionality that overlapped with
SockAddr_cidr_mask.  Doing the conversion after we've collected the
netmask seems a lot cleaner to me.  Also, this way keeps a fairly decent
separation of interests between hba.c (parsing the hba.conf syntax) and
ip.c (messing with address representations).

> While talking about beauty: that setting of *cidr_slash to '/' and 0
> doesn't look too esthetic...

It is ugly (and I didn't write it ;-)).  But if we palloc'd a modified
version of the token we'd have to remember to pfree it, so it nets out
to about the same amount of code either way I think.  If you wanna try
to clean it up more, be my guest ...

            regards, tom lane

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

Предыдущее
От: Mark Kirkwood
Дата:
Сообщение: Re: Minor verbosity increase for analyze
Следующее
От: Neil Conway
Дата:
Сообщение: Re: minor documentation improvements