Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit95a03e9

Browse files
committed
Another round of code cleanup on bufmgr. Use BM_VALID flag to keep track
of whether we have successfully read data into a buffer; this makes theerror behavior a bit more transparent (IMHO anyway), and also makes itwork correctly for local buffers which don't use Start/TerminateBufferIO.Collapse three separate functions for writing a shared buffer into one.This overlaps a bit with cleanups that Neil proposed awhile back, butseems not to have committed yet.
1 parentaeee856 commit95a03e9

File tree

6 files changed

+326
-426
lines changed

6 files changed

+326
-426
lines changed

‎src/backend/storage/buffer/buf_init.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $PostgreSQL: pgsql/src/backend/storage/buffer/buf_init.c,v 1.63 2004/04/19 23:27:17 tgl Exp $
11+
* $PostgreSQL: pgsql/src/backend/storage/buffer/buf_init.c,v 1.64 2004/04/21 18:06:30 tgl Exp $
1212
*
1313
*-------------------------------------------------------------------------
1414
*/
@@ -133,11 +133,11 @@ InitBufferPool(void)
133133

134134
buf->bufNext=i+1;
135135

136-
CLEAR_BUFFERTAG(&(buf->tag));
136+
CLEAR_BUFFERTAG(buf->tag);
137137
buf->buf_id=i;
138138

139139
buf->data=MAKE_OFFSET(block);
140-
buf->flags=(BM_DELETED |BM_VALID);
140+
buf->flags=0;
141141
buf->refcount=0;
142142
buf->io_in_progress_lock=LWLockAssign();
143143
buf->cntx_lock=LWLockAssign();

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp