summaryrefslogtreecommitdiff
path: root/src/interfaces
diff options
context:
space:
mode:
Diffstat (limited to 'src/interfaces')
-rw-r--r--src/interfaces/libpq/legacy-pqsignal.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/interfaces/libpq/legacy-pqsignal.c b/src/interfaces/libpq/legacy-pqsignal.c
index 08648885623..ebd1695bf07 100644
--- a/src/interfaces/libpq/legacy-pqsignal.c
+++ b/src/interfaces/libpq/legacy-pqsignal.c
@@ -28,8 +28,16 @@
* with the semantics it had in 9.2; in particular, this has different
* behavior for SIGALRM than the version in src/port/pqsignal.c.
*
- * libpq itself does not use this.
+ * libpq itself does not use this, nor does anything else in our code.
+ *
+ * src/include/port.h #define's pqsignal as pqsignal_fe or pqsignal_be,
+ * but here we want to export just plain "pqsignal". We can't rely on
+ * port.h's extern declaration either. (The point of those #define's
+ * is to ensure that no in-tree code accidentally calls this version.)
*/
+#undef pqsignal
+extern pqsigfunc pqsignal(int signo, pqsigfunc func);
+
pqsigfunc
pqsignal(int signo, pqsigfunc func)
{