Ooops, missed that a couple of contrib modules have calls to byteacmp.
Add bytea.h inclusions as needed. Some of the contrib regression tests need to be de-hexified, too. Per buildfarm.
This commit is contained in:
parent
5b8ee5c128
commit
bcba09e27c
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* $PostgreSQL: pgsql/contrib/btree_gin/btree_gin.c,v 1.2 2009/06/11 14:48:50 momjian Exp $
|
* $PostgreSQL: pgsql/contrib/btree_gin/btree_gin.c,v 1.3 2009/08/04 18:49:50 tgl Exp $
|
||||||
*/
|
*/
|
||||||
#include "postgres.h"
|
#include "postgres.h"
|
||||||
|
|
||||||
@ -8,6 +8,7 @@
|
|||||||
#include "fmgr.h"
|
#include "fmgr.h"
|
||||||
#include "access/skey.h"
|
#include "access/skey.h"
|
||||||
#include "utils/builtins.h"
|
#include "utils/builtins.h"
|
||||||
|
#include "utils/bytea.h"
|
||||||
#include "utils/cash.h"
|
#include "utils/cash.h"
|
||||||
#include "utils/date.h"
|
#include "utils/date.h"
|
||||||
#include "utils/inet.h"
|
#include "utils/inet.h"
|
||||||
|
@ -1,4 +1,6 @@
|
|||||||
set enable_seqscan=off;
|
set enable_seqscan=off;
|
||||||
|
-- ensure consistent test output regardless of the default bytea format
|
||||||
|
SET bytea_output TO escape;
|
||||||
CREATE TABLE test_bytea (
|
CREATE TABLE test_bytea (
|
||||||
i bytea
|
i bytea
|
||||||
);
|
);
|
||||||
|
@ -1,4 +1,6 @@
|
|||||||
set enable_seqscan=off;
|
set enable_seqscan=off;
|
||||||
|
-- ensure consistent test output regardless of the default bytea format
|
||||||
|
SET bytea_output TO escape;
|
||||||
|
|
||||||
CREATE TABLE test_bytea (
|
CREATE TABLE test_bytea (
|
||||||
i bytea
|
i bytea
|
||||||
|
@ -1,9 +1,9 @@
|
|||||||
/*
|
/*
|
||||||
* $PostgreSQL: pgsql/contrib/btree_gist/btree_bit.c,v 1.10 2009/06/11 14:48:50 momjian Exp $
|
* $PostgreSQL: pgsql/contrib/btree_gist/btree_bit.c,v 1.11 2009/08/04 18:49:50 tgl Exp $
|
||||||
*/
|
*/
|
||||||
#include "btree_gist.h"
|
#include "btree_gist.h"
|
||||||
#include "btree_utils_var.h"
|
#include "btree_utils_var.h"
|
||||||
#include "utils/builtins.h"
|
#include "utils/bytea.h"
|
||||||
#include "utils/varbit.h"
|
#include "utils/varbit.h"
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,9 +1,9 @@
|
|||||||
/*
|
/*
|
||||||
* $PostgreSQL: pgsql/contrib/btree_gist/btree_bytea.c,v 1.9 2009/06/11 14:48:50 momjian Exp $
|
* $PostgreSQL: pgsql/contrib/btree_gist/btree_bytea.c,v 1.10 2009/08/04 18:49:50 tgl Exp $
|
||||||
*/
|
*/
|
||||||
#include "btree_gist.h"
|
#include "btree_gist.h"
|
||||||
#include "btree_utils_var.h"
|
#include "btree_utils_var.h"
|
||||||
#include "utils/builtins.h"
|
#include "utils/bytea.h"
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -737,18 +737,6 @@ SELECT 'f'::citext::"char" = 'f'::"char" AS t;
|
|||||||
t
|
t
|
||||||
(1 row)
|
(1 row)
|
||||||
|
|
||||||
SELECT 'foo'::bytea::citext = 'foo' AS t;
|
|
||||||
t
|
|
||||||
---
|
|
||||||
t
|
|
||||||
(1 row)
|
|
||||||
|
|
||||||
SELECT 'foo'::citext::bytea = 'foo'::bytea AS t;
|
|
||||||
t
|
|
||||||
---
|
|
||||||
t
|
|
||||||
(1 row)
|
|
||||||
|
|
||||||
SELECT '100'::money::citext = '$100.00' AS t;
|
SELECT '100'::money::citext = '$100.00' AS t;
|
||||||
t
|
t
|
||||||
---
|
---
|
||||||
|
@ -737,18 +737,6 @@ SELECT 'f'::citext::"char" = 'f'::"char" AS t;
|
|||||||
t
|
t
|
||||||
(1 row)
|
(1 row)
|
||||||
|
|
||||||
SELECT 'foo'::bytea::citext = 'foo' AS t;
|
|
||||||
t
|
|
||||||
---
|
|
||||||
t
|
|
||||||
(1 row)
|
|
||||||
|
|
||||||
SELECT 'foo'::citext::bytea = 'foo'::bytea AS t;
|
|
||||||
t
|
|
||||||
---
|
|
||||||
t
|
|
||||||
(1 row)
|
|
||||||
|
|
||||||
SELECT '100'::money::citext = '$100.00' AS t;
|
SELECT '100'::money::citext = '$100.00' AS t;
|
||||||
t
|
t
|
||||||
---
|
---
|
||||||
|
@ -226,9 +226,6 @@ SELECT 'f'::citext::char = 'f'::char AS t;
|
|||||||
SELECT 'f'::"char"::citext = 'f' AS t;
|
SELECT 'f'::"char"::citext = 'f' AS t;
|
||||||
SELECT 'f'::citext::"char" = 'f'::"char" AS t;
|
SELECT 'f'::citext::"char" = 'f'::"char" AS t;
|
||||||
|
|
||||||
SELECT 'foo'::bytea::citext = 'foo' AS t;
|
|
||||||
SELECT 'foo'::citext::bytea = 'foo'::bytea AS t;
|
|
||||||
|
|
||||||
SELECT '100'::money::citext = '$100.00' AS t;
|
SELECT '100'::money::citext = '$100.00' AS t;
|
||||||
SELECT '100'::citext::money = '100'::money AS t;
|
SELECT '100'::citext::money = '100'::money AS t;
|
||||||
|
|
||||||
|
@ -1,6 +1,8 @@
|
|||||||
--
|
--
|
||||||
-- Blowfish cipher
|
-- Blowfish cipher
|
||||||
--
|
--
|
||||||
|
-- ensure consistent test output regardless of the default bytea format
|
||||||
|
SET bytea_output TO escape;
|
||||||
-- some standard Blowfish testvalues
|
-- some standard Blowfish testvalues
|
||||||
SELECT encode(encrypt(
|
SELECT encode(encrypt(
|
||||||
decode('0000000000000000', 'hex'),
|
decode('0000000000000000', 'hex'),
|
||||||
|
@ -8,6 +8,8 @@
|
|||||||
SET client_min_messages = warning;
|
SET client_min_messages = warning;
|
||||||
\set ECHO none
|
\set ECHO none
|
||||||
RESET client_min_messages;
|
RESET client_min_messages;
|
||||||
|
-- ensure consistent test output regardless of the default bytea format
|
||||||
|
SET bytea_output TO escape;
|
||||||
-- check for encoding fn's
|
-- check for encoding fn's
|
||||||
SELECT encode('foo', 'hex');
|
SELECT encode('foo', 'hex');
|
||||||
encode
|
encode
|
||||||
|
@ -1,6 +1,8 @@
|
|||||||
--
|
--
|
||||||
-- PGP Armor
|
-- PGP Armor
|
||||||
--
|
--
|
||||||
|
-- ensure consistent test output regardless of the default bytea format
|
||||||
|
SET bytea_output TO escape;
|
||||||
select armor('');
|
select armor('');
|
||||||
armor
|
armor
|
||||||
-----------------------------
|
-----------------------------
|
||||||
|
@ -1,6 +1,8 @@
|
|||||||
--
|
--
|
||||||
-- PGP encrypt
|
-- PGP encrypt
|
||||||
--
|
--
|
||||||
|
-- ensure consistent test output regardless of the default bytea format
|
||||||
|
SET bytea_output TO escape;
|
||||||
select pgp_sym_decrypt(pgp_sym_encrypt('Secret.', 'key'), 'key');
|
select pgp_sym_decrypt(pgp_sym_encrypt('Secret.', 'key'), 'key');
|
||||||
pgp_sym_decrypt
|
pgp_sym_decrypt
|
||||||
-----------------
|
-----------------
|
||||||
|
@ -1,6 +1,8 @@
|
|||||||
--
|
--
|
||||||
-- PGP Public Key Encryption
|
-- PGP Public Key Encryption
|
||||||
--
|
--
|
||||||
|
-- ensure consistent test output regardless of the default bytea format
|
||||||
|
SET bytea_output TO escape;
|
||||||
-- successful encrypt/decrypt
|
-- successful encrypt/decrypt
|
||||||
select pgp_pub_decrypt(
|
select pgp_pub_decrypt(
|
||||||
pgp_pub_encrypt('Secret msg', dearmor(pubkey)),
|
pgp_pub_encrypt('Secret msg', dearmor(pubkey)),
|
||||||
|
@ -1,6 +1,8 @@
|
|||||||
--
|
--
|
||||||
-- AES / Rijndael-128 cipher
|
-- AES / Rijndael-128 cipher
|
||||||
--
|
--
|
||||||
|
-- ensure consistent test output regardless of the default bytea format
|
||||||
|
SET bytea_output TO escape;
|
||||||
-- some standard Rijndael testvalues
|
-- some standard Rijndael testvalues
|
||||||
SELECT encode(encrypt(
|
SELECT encode(encrypt(
|
||||||
decode('00112233445566778899aabbccddeeff', 'hex'),
|
decode('00112233445566778899aabbccddeeff', 'hex'),
|
||||||
|
@ -1,6 +1,8 @@
|
|||||||
--
|
--
|
||||||
-- Blowfish cipher
|
-- Blowfish cipher
|
||||||
--
|
--
|
||||||
|
-- ensure consistent test output regardless of the default bytea format
|
||||||
|
SET bytea_output TO escape;
|
||||||
|
|
||||||
-- some standard Blowfish testvalues
|
-- some standard Blowfish testvalues
|
||||||
SELECT encode(encrypt(
|
SELECT encode(encrypt(
|
||||||
|
@ -12,6 +12,9 @@ SET client_min_messages = warning;
|
|||||||
\set ECHO all
|
\set ECHO all
|
||||||
RESET client_min_messages;
|
RESET client_min_messages;
|
||||||
|
|
||||||
|
-- ensure consistent test output regardless of the default bytea format
|
||||||
|
SET bytea_output TO escape;
|
||||||
|
|
||||||
-- check for encoding fn's
|
-- check for encoding fn's
|
||||||
SELECT encode('foo', 'hex');
|
SELECT encode('foo', 'hex');
|
||||||
SELECT decode('666f6f', 'hex');
|
SELECT decode('666f6f', 'hex');
|
||||||
|
@ -1,6 +1,8 @@
|
|||||||
--
|
--
|
||||||
-- PGP Armor
|
-- PGP Armor
|
||||||
--
|
--
|
||||||
|
-- ensure consistent test output regardless of the default bytea format
|
||||||
|
SET bytea_output TO escape;
|
||||||
|
|
||||||
select armor('');
|
select armor('');
|
||||||
select armor('test');
|
select armor('test');
|
||||||
|
@ -1,6 +1,8 @@
|
|||||||
--
|
--
|
||||||
-- PGP encrypt
|
-- PGP encrypt
|
||||||
--
|
--
|
||||||
|
-- ensure consistent test output regardless of the default bytea format
|
||||||
|
SET bytea_output TO escape;
|
||||||
|
|
||||||
select pgp_sym_decrypt(pgp_sym_encrypt('Secret.', 'key'), 'key');
|
select pgp_sym_decrypt(pgp_sym_encrypt('Secret.', 'key'), 'key');
|
||||||
|
|
||||||
|
@ -1,6 +1,8 @@
|
|||||||
--
|
--
|
||||||
-- PGP Public Key Encryption
|
-- PGP Public Key Encryption
|
||||||
--
|
--
|
||||||
|
-- ensure consistent test output regardless of the default bytea format
|
||||||
|
SET bytea_output TO escape;
|
||||||
|
|
||||||
-- successful encrypt/decrypt
|
-- successful encrypt/decrypt
|
||||||
select pgp_pub_decrypt(
|
select pgp_pub_decrypt(
|
||||||
|
@ -1,6 +1,8 @@
|
|||||||
--
|
--
|
||||||
-- AES / Rijndael-128 cipher
|
-- AES / Rijndael-128 cipher
|
||||||
--
|
--
|
||||||
|
-- ensure consistent test output regardless of the default bytea format
|
||||||
|
SET bytea_output TO escape;
|
||||||
|
|
||||||
-- some standard Rijndael testvalues
|
-- some standard Rijndael testvalues
|
||||||
SELECT encode(encrypt(
|
SELECT encode(encrypt(
|
||||||
|
Loading…
x
Reference in New Issue
Block a user