Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
Postgres FD Implementation
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Abuhujair Javed
Postgres FD Implementation
Commits
1b9dea04
Commit
1b9dea04
authored
Jan 11, 2012
by
Heikki Linnakangas
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove useless 'needlock' argument from GetXLogInsertRecPtr. It was always
passed as 'true'.
parent
9c808f89
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
7 deletions
+5
-7
src/backend/access/transam/xlog.c
src/backend/access/transam/xlog.c
+3
-5
src/backend/access/transam/xlogfuncs.c
src/backend/access/transam/xlogfuncs.c
+1
-1
src/include/access/xlog.h
src/include/access/xlog.h
+1
-1
No files found.
src/backend/access/transam/xlog.c
View file @
1b9dea04
...
...
@@ -9411,16 +9411,14 @@ GetStandbyFlushRecPtr(void)
* Get latest WAL insert pointer
*/
XLogRecPtr
GetXLogInsertRecPtr
(
bool
needlock
)
GetXLogInsertRecPtr
(
void
)
{
XLogCtlInsert
*
Insert
=
&
XLogCtl
->
Insert
;
XLogRecPtr
current_recptr
;
if
(
needlock
)
LWLockAcquire
(
WALInsertLock
,
LW_SHARED
);
LWLockAcquire
(
WALInsertLock
,
LW_SHARED
);
INSERT_RECPTR
(
current_recptr
,
Insert
,
Insert
->
curridx
);
if
(
needlock
)
LWLockRelease
(
WALInsertLock
);
LWLockRelease
(
WALInsertLock
);
return
current_recptr
;
}
...
...
src/backend/access/transam/xlogfuncs.c
View file @
1b9dea04
...
...
@@ -200,7 +200,7 @@ pg_current_xlog_insert_location(PG_FUNCTION_ARGS)
errmsg
(
"recovery is in progress"
),
errhint
(
"WAL control functions cannot be executed during recovery."
)));
current_recptr
=
GetXLogInsertRecPtr
(
true
);
current_recptr
=
GetXLogInsertRecPtr
();
snprintf
(
location
,
sizeof
(
location
),
"%X/%X"
,
current_recptr
.
xlogid
,
current_recptr
.
xrecoff
);
...
...
src/include/access/xlog.h
View file @
1b9dea04
...
...
@@ -288,7 +288,7 @@ extern bool XLogInsertAllowed(void);
extern
void
GetXLogReceiptTime
(
TimestampTz
*
rtime
,
bool
*
fromStream
);
extern
XLogRecPtr
GetXLogReplayRecPtr
(
XLogRecPtr
*
restoreLastRecPtr
);
extern
XLogRecPtr
GetStandbyFlushRecPtr
(
void
);
extern
XLogRecPtr
GetXLogInsertRecPtr
(
bool
needlock
);
extern
XLogRecPtr
GetXLogInsertRecPtr
(
void
);
extern
XLogRecPtr
GetXLogWriteRecPtr
(
void
);
extern
bool
RecoveryIsPaused
(
void
);
extern
void
SetRecoveryPause
(
bool
recoveryPause
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment