postgres.git / summary / log / commit / refs

commit    6c997712cfed99dbf226ecbcb47c1dbf5673e5c4
Author:   Alvaro Herrera <alvherre@alvh.no-ip.org>
Date:     Wed Jun 06 18:46:53 2018 +0000
First released in: 11.0, 9.3.24, 9.4.19, 9.5.14, 9.6.10, 10.5

    Fix function code in error report
    
    This bug causes a lseek() failure to be reported as a "could not open"
    failure in the error message, muddling bug reports.  I introduced this
    copy-and-pasteo in commit 78e122010422.
    
    Noticed while reviewing code for bug report #15221, from lily liang.  In
    version 10 the affected function is only used by multixact.c and
    commit_ts, and only in corner-case circumstances, neither of which are
    involved in the reported bug (a pg_subtrans failure.)
    
    Author: Álvaro Herrera


src/backend/access/transam/slru.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/backend/access/transam/slru.c b/src/backend/access/transam/slru.c index 90c7cf56e63..e098cebabf0 100644 --- a/src/backend/access/transam/slru.c +++ b/src/backend/access/transam/slru.c @@ -598,7 +598,7 @@ SimpleLruDoesPhysicalPageExist(SlruCtl ctl, int pageno) if ((endpos = lseek(fd, 0, SEEK_END)) < 0) { - slru_errcause = SLRU_OPEN_FAILED; + slru_errcause = SLRU_SEEK_FAILED; slru_errno = errno; SlruReportIOError(ctl, pageno, 0); } [parent: 790259528fd1]