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
ddc5bc95
Commit
ddc5bc95
authored
Mar 18, 2001
by
Tom Lane
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
When we add 'waiting' to the ps_status display, there should be a
space in front of it. Improve comments a little.
parent
934126b5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
5 deletions
+6
-5
src/backend/storage/lmgr/lock.c
src/backend/storage/lmgr/lock.c
+6
-5
No files found.
src/backend/storage/lmgr/lock.c
View file @
ddc5bc95
...
...
@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lock.c,v 1.8
6 2001/03/14 18:24:32 momjian
Exp $
* $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lock.c,v 1.8
7 2001/03/18 20:13:13 tgl
Exp $
*
* NOTES
* Outside modules can create a lock table and acquire/release
...
...
@@ -934,11 +934,11 @@ WaitOnLock(LOCKMETHOD lockmethod, LOCKMODE lockmode,
old_status
=
pstrdup
(
get_ps_display
());
new_status
=
(
char
*
)
palloc
(
strlen
(
old_status
)
+
10
);
strcpy
(
new_status
,
old_status
);
strcat
(
new_status
,
"waiting"
);
strcat
(
new_status
,
"
waiting"
);
set_ps_display
(
new_status
);
/*
* NOTE: Think not to put any
lock
state cleanup after the call to
* NOTE: Think not to put any
shared-
state cleanup after the call to
* ProcSleep, in either the normal or failure path. The lock state
* must be fully set by the lock grantor, or by HandleDeadLock if we
* give up waiting for the lock. This is necessary because of the
...
...
@@ -946,7 +946,9 @@ WaitOnLock(LOCKMETHOD lockmethod, LOCKMODE lockmode,
* after someone else grants us the lock, but before we've noticed it.
* Hence, after granting, the locktable state must fully reflect the
* fact that we own the lock; we can't do additional work on return.
*
* Contrariwise, if we fail, any cleanup must happen in xact abort
* processing, not here, to ensure it will also happen in the cancel/die
* case.
*/
if
(
ProcSleep
(
lockMethodTable
,
...
...
@@ -958,7 +960,6 @@ WaitOnLock(LOCKMETHOD lockmethod, LOCKMODE lockmode,
* We failed as a result of a deadlock, see HandleDeadLock().
* Quit now. Removal of the holder and lock objects, if no longer
* needed, will happen in xact cleanup (see above for motivation).
*
*/
LOCK_PRINT
(
"WaitOnLock: aborting on lock"
,
lock
,
lockmode
);
SpinRelease
(
lockMethodTable
->
ctl
->
masterLock
);
...
...
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