pgsql: Arrange for the pg_foo_is_visible and has_foo_privilege families

Поиск
Список
Период
Сортировка
От tgl@postgresql.org (Tom Lane)
Тема pgsql: Arrange for the pg_foo_is_visible and has_foo_privilege families
Дата
Msg-id 20081215180941.43B5D7563FE@cvs.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Log Message:
-----------
Arrange for the pg_foo_is_visible and has_foo_privilege families of functions
to return NULL, instead of erroring out, if the target object is specified by
OID and we can't find that OID in the catalogs.  Since these functions operate
internally on SnapshotNow rules, there is a race condition when using them
in user queries: the query's MVCC snapshot might "see" a catalog row that's
already committed dead, leading to a failure when the inquiry function is
applied.  Returning NULL should generally provide more convenient behavior.
This issue has been complained of before, and in particular we are now seeing
it in the regression tests due to another recent patch.

Modified Files:
--------------
    pgsql/src/backend/catalog:
        namespace.c (r1.113 -> r1.114)
        (http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/catalog/namespace.c?r1=1.113&r2=1.114)
    pgsql/src/backend/utils/adt:
        acl.c (r1.142 -> r1.143)
        (http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/acl.c?r1=1.142&r2=1.143)
    pgsql/src/test/regress/expected:
        privileges.out (r1.40 -> r1.41)
        (http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/privileges.out?r1=1.40&r2=1.41)

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

Предыдущее
От: tgl@postgresql.org (Tom Lane)
Дата:
Сообщение: pgsql: Remove newly-added regression test cases that referenced
Следующее
От: Simon Riggs
Дата:
Сообщение: Re: pgsql: Do not try to change a const variable.