git.postgresql.org Git - postgresql.git/commitdiff

git projects / postgresql.git / commitdiff
? search:
summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 153836b)
Remove unused ShutdownLatchSupport() function
Wed, 5 Mar 2025 21:46:29 +0000 (23:46 +0200)
Wed, 5 Mar 2025 21:52:04 +0000 (23:52 +0200)
The only caller was removed in commit 80a8f95b3b. I don't foresee
needing it any time soon, and I'm working on some big changes in this
area, so let's remove it out of the way.

Reviewed-by: Andres Freund <andres@anarazel.de>
Discussion: https://www.postgresql.org/message-id/8a507fb6-df28-49d3-81a5-ede180d7f0fb@iki.fi


diff --git a/src/backend/storage/ipc/latch.c b/src/backend/storage/ipc/latch.c
index 4572684f2242e8a142bd9640adfb00b412a85bcb..cd09a10f3d118056ed47198b3f3248b61d31416e 100644 (file)
--- a/src/backend/storage/ipc/latch.c
+++ b/src/backend/storage/ipc/latch.c
@@ -360,33 +360,6 @@ InitializeLatchWaitSet(void)
Assert(latch_pos == LatchWaitSetLatchPos);
}
-void
-ShutdownLatchSupport(void)
-{
-#if defined(WAIT_USE_POLL)
- pqsignal(SIGURG, SIG_IGN);
-#endif
-
- if (LatchWaitSet)
- {
- FreeWaitEventSet(LatchWaitSet);
- LatchWaitSet = NULL;
- }
-
-#if defined(WAIT_USE_SELF_PIPE)
- close(selfpipe_readfd);
- close(selfpipe_writefd);
- selfpipe_readfd = -1;
- selfpipe_writefd = -1;
- selfpipe_owner_pid = InvalidPid;
-#endif
-
-#if defined(WAIT_USE_SIGNALFD)
- close(signal_fd);
- signal_fd = -1;
-#endif
-}
-
/*
* Initialize a process-local latch.
*/
diff --git a/src/include/storage/latch.h b/src/include/storage/latch.h
index bf568124df9246be00d785c7fc130288b25f15ff..66e7a5b7c08cddcd60c4ea4463662324f071a6a4 100644 (file)
--- a/src/include/storage/latch.h
+++ b/src/include/storage/latch.h
@@ -173,7 +173,6 @@ extern void OwnLatch(Latch *latch);
extern void DisownLatch(Latch *latch);
extern void SetLatch(Latch *latch);
extern void ResetLatch(Latch *latch);
-extern void ShutdownLatchSupport(void);
extern WaitEventSet *CreateWaitEventSet(ResourceOwner resowner, int nevents);
extern void FreeWaitEventSet(WaitEventSet *set);
This is the main PostgreSQL git repository.
RSS Atom

AltStyle によって変換されたページ (->オリジナル) /