summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAmit Kapila <akapila@postgresql.org>2020-03-18 10:08:56 +0530
committerAmit Kapila <akapila@postgresql.org>2020-03-18 10:08:56 +0530
commitfe27ce1c136d191b46717fda55b267a2d26f806c (patch)
tree42ba681166c163f4703625fffb94c020480c1a5f /src
parent9a9b87191a32fb97dbd9cad6d9a8a43a9fc31c16 (diff)
Add missing errcode() in a few ereport calls.
This will allow to specifying SQLSTATE error code for the errors in the missing places. Reported-by: Sawada Masahiko Author: Sawada Masahiko Backpatch-through: 9.5 Discussion: https://postgr.es/m/CA+fd4k6N8EjNvZpM8nme+y+05mz-SM8Z_BgkixzkA34R+ej0Kw@mail.gmail.com
Diffstat (limited to 'src')
-rw-r--r--src/backend/storage/page/bufpage.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/backend/storage/page/bufpage.c b/src/backend/storage/page/bufpage.c
index 11607827d8d..bf0d3494bd3 100644
--- a/src/backend/storage/page/bufpage.c
+++ b/src/backend/storage/page/bufpage.c
@@ -140,7 +140,7 @@ PageIsVerified(Page page, BlockNumber blkno)
if (checksum_failure)
{
ereport(WARNING,
- (ERRCODE_DATA_CORRUPTED,
+ (errcode(ERRCODE_DATA_CORRUPTED),
errmsg("page verification failed, calculated checksum %u but expected %u",
checksum, p->pd_checksum)));