Skip to content

Commit 664da2a

Browse files
committed
Fix comment in regression tests for large objects
The values assigned to INV_WRITE and INV_READ were reversed in the tests, which would be confusing when writing tests specific to read or write operations on LOs. Author: Yugo Nagata Discussion: https://postgr.es/m/20220527153028.61a4608f66abcd026fd3806f@sraoss.co.jp
1 parent b7658c2 commit 664da2a

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

src/test/regress/expected/largeobject.out

+2-2
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,8 @@ INSERT INTO lotest_stash_values (loid) SELECT lo_creat(42);
5050
BEGIN;
5151
-- lo_open(lobjId oid, mode integer) returns integer
5252
-- The mode parameter to lo_open uses two constants:
53-
-- INV_READ = 0x20000
54-
-- INV_WRITE = 0x40000
53+
-- INV_WRITE = 0x20000
54+
-- INV_READ = 0x40000
5555
-- The return value is a file descriptor-like value which remains valid for the
5656
-- transaction.
5757
UPDATE lotest_stash_values SET fd = lo_open(loid, CAST(x'20000' | x'40000' AS integer));

src/test/regress/expected/largeobject_1.out

+2-2
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,8 @@ INSERT INTO lotest_stash_values (loid) SELECT lo_creat(42);
5050
BEGIN;
5151
-- lo_open(lobjId oid, mode integer) returns integer
5252
-- The mode parameter to lo_open uses two constants:
53-
-- INV_READ = 0x20000
54-
-- INV_WRITE = 0x40000
53+
-- INV_WRITE = 0x20000
54+
-- INV_READ = 0x40000
5555
-- The return value is a file descriptor-like value which remains valid for the
5656
-- transaction.
5757
UPDATE lotest_stash_values SET fd = lo_open(loid, CAST(x'20000' | x'40000' AS integer));

src/test/regress/sql/largeobject.sql

+2-2
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,8 @@ BEGIN;
3434

3535
-- lo_open(lobjId oid, mode integer) returns integer
3636
-- The mode parameter to lo_open uses two constants:
37-
-- INV_READ = 0x20000
38-
-- INV_WRITE = 0x40000
37+
-- INV_WRITE = 0x20000
38+
-- INV_READ = 0x40000
3939
-- The return value is a file descriptor-like value which remains valid for the
4040
-- transaction.
4141
UPDATE lotest_stash_values SET fd = lo_open(loid, CAST(x'20000' | x'40000' AS integer));

0 commit comments

Comments
 (0)