1
0
mirror of https://github.com/postgres/postgres.git synced 2025-09-02 04:21:28 +03:00

redo/undo support functions and cleanups.

This commit is contained in:
Vadim B. Mikheev
2000-10-20 11:01:21 +00:00
parent e18a862d46
commit b58c0411ba
15 changed files with 726 additions and 167 deletions

View File

@@ -7,7 +7,7 @@
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
* Portions Copyright (c) 1994, Regents of the University of California
*
* $Id: bufmgr.h,v 1.40 2000/08/07 20:15:50 tgl Exp $
* $Id: bufmgr.h,v 1.41 2000/10/20 11:01:21 vadim Exp $
*
*-------------------------------------------------------------------------
*/
@@ -44,6 +44,17 @@ extern int ShowPinTrace;
#define BUFFER_LOCK_SHARE 1
#define BUFFER_LOCK_EXCLUSIVE 2
#define UnlockAndReleaseBuffer(buffer) \
( \
LockBuffer(buffer, BUFFER_LOCK_UNLOCK), \
ReleaseBuffer(buffer) \
)
#define UnlockAndWriteBuffer(buffer) \
( \
LockBuffer(buffer, BUFFER_LOCK_UNLOCK), \
WriteBuffer(buffer) \
)
/*
* BufferIsValid
@@ -163,4 +174,7 @@ extern void UnlockBuffers(void);
extern void LockBuffer(Buffer buffer, int mode);
extern void AbortBufferIO(void);
extern bool BufferIsUpdatable(Buffer buffer);
extern void MarkBufferForCleanup(Buffer buffer, void (*CleanupFunc)(Buffer));
#endif