pgsql: Add assign_expr_collations() to CreatePolicy() and AlterPolicy()

Started by Joe Conwayalmost 11 years ago4 messagescomitters
Jump to latest
#1Joe Conway
mail@joeconway.com

Add assign_expr_collations() to CreatePolicy() and AlterPolicy().

As noted by Noah Misch, CreatePolicy() and AlterPolicy() omit to call
assign_expr_collations() on the node trees. Fix the omission and add
his test case to the rowsecurity regression test.

Branch
------
REL9_5_STABLE

Details
-------
http://git.postgresql.org/pg/commitdiff/7236f5b068ca78bb3e771f62ee1365ba945d4869

Modified Files
--------------
src/backend/commands/policy.c | 10 ++++++++++
src/test/regress/expected/rowsecurity.out | 21 +++++++++++++++++++++
src/test/regress/sql/rowsecurity.sql | 12 ++++++++++++
3 files changed, 43 insertions(+)

--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers

#2Bruce Momjian
bruce@momjian.us
In reply to: Joe Conway (#1)
Re: pgsql: Add assign_expr_collations() to CreatePolicy() and AlterPolicy()

On Sat, Jul 11, 2015 at 09:20:41PM +0000, Joe Conway wrote:

Add assign_expr_collations() to CreatePolicy() and AlterPolicy().

As noted by Noah Misch, CreatePolicy() and AlterPolicy() omit to call
assign_expr_collations() on the node trees. Fix the omission and add
his test case to the rowsecurity regression test.

I think this commit has added a compiler warning:

policy.c:542: warning: implicit declaration of function 'assign_expr_collations'

--
Bruce Momjian <bruce@momjian.us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ Everyone has their own god. +

--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers

#3Tom Lane
tgl@sss.pgh.pa.us
In reply to: Bruce Momjian (#2)
Re: pgsql: Add assign_expr_collations() to CreatePolicy() and AlterPolicy()

Bruce Momjian <bruce@momjian.us> writes:

On Sat, Jul 11, 2015 at 09:20:41PM +0000, Joe Conway wrote:

Add assign_expr_collations() to CreatePolicy() and AlterPolicy().

I think this commit has added a compiler warning:
policy.c:542: warning: implicit declaration of function 'assign_expr_collations'

Indeed ... fixed.

regards, tom lane

--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers

#4Joe Conway
mail@joeconway.com
In reply to: Tom Lane (#3)
Re: pgsql: Add assign_expr_collations() to CreatePolicy() and AlterPolicy()

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 07/11/2015 08:35 PM, Tom Lane wrote:

Bruce Momjian <bruce@momjian.us> writes:

On Sat, Jul 11, 2015 at 09:20:41PM +0000, Joe Conway wrote:

Add assign_expr_collations() to CreatePolicy() and
AlterPolicy().

I think this commit has added a compiler warning: policy.c:542:
warning: implicit declaration of function
'assign_expr_collations'

Mea culpa.

Indeed ... fixed.

Thanks for that. Will be sure to do better next time.

Joe

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQIcBAEBAgAGBQJVom6gAAoJEDfy90M199hlm4sP/3dhY2D1I9nluP93D3ikAZfG
FXA8/KlCF9igU43Yp3CnwMInZ+SpvMbaat5+inCe/l5fjhak/DcYCtCfrYqqeCBS
mJi1h0dRQYsQkzZwd2NeEJHVna2Olg63McRBDEqLoan99zgfqrwNcAqeiImRUZ5U
jv+YVOo8U3mTIay2w7MwhDKofKANMU9hP6mOzkCCNJtt7YXkfTa+AFSfrzjrUl24
RTq97uiaHRraNumOa0ywbLsi+rGi41BjHhS8mxgX3e1wZMsZoKNnJduJc2TF3vAn
a5mHQ+IO81vp3rB98o3A7JzVf9jP2knTwo2BYppwufyZqx2uYFnoAJKgVaS9M/Vj
Wb51p5afbs/hBy2Xt0nRELUSyxk8woOsw4CaLYT78WwM3f/rg8q4Mtd9wzV8QeOf
V4KWNmKZmFp/5i59ohrjzHcQZ52jo9I84pi115Wy0eipqynnZwbYcbmVo44NRQ3e
jz18vIgJfmI48qbOh2oNVrVnqg9sCGvtPb9DmP8FVE86nei+D2kb/ew2KlqRVm83
gWDORC39IwGVfzx9ZIJDU/j0l7PRKaS9Sf7RQutcth9Cxt43BaXhYVv5m4RBhCcU
z1ZZTOoAZ6QKrQb2O5qD5lI4zbGJ5W0YK1NC3GlApMYAhTrjcWDewEiUegQUrzD5
22lVxBYBl59o0Roi4Mmn
=hjZj
-----END PGP SIGNATURE-----

--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers