summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2007-10-02 00:25:20 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2007-10-02 00:25:20 +0000
commitf1d37a9997ef8b00d53267ddfd0f5d7975017085 (patch)
tree9456d7df97201ddf4729e06c133d47b037235095 /src
parenteb9f280ca78e9b8b28c88911ed45e8e59a04b997 (diff)
Cope with ERR_set_mark() and ERR_pop_to_mark() not existing in older
OpenSSL libraries --- just don't call them if they're not there. This might possibly lead to misleading error messages, but we'll just have to live with that.
Diffstat (limited to 'src')
-rw-r--r--src/include/pg_config.h.in3
-rw-r--r--src/interfaces/libpq/fe-secure.c8
2 files changed, 10 insertions, 1 deletions
diff --git a/src/include/pg_config.h.in b/src/include/pg_config.h.in
index 0f583953769..f0b5230e511 100644
--- a/src/include/pg_config.h.in
+++ b/src/include/pg_config.h.in
@@ -118,6 +118,9 @@
/* Define to 1 if you have the <editline/readline.h> header file. */
#undef HAVE_EDITLINE_READLINE_H
+/* Define to 1 if you have the `ERR_set_mark' function. */
+#undef HAVE_ERR_SET_MARK
+
/* Define to 1 if you have the `fcvt' function. */
#undef HAVE_FCVT
diff --git a/src/interfaces/libpq/fe-secure.c b/src/interfaces/libpq/fe-secure.c
index b50d095fe0d..27e4efa6413 100644
--- a/src/interfaces/libpq/fe-secure.c
+++ b/src/interfaces/libpq/fe-secure.c
@@ -11,7 +11,7 @@
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/interfaces/libpq/fe-secure.c,v 1.95 2007/10/01 20:30:06 mha Exp $
+ * $PostgreSQL: pgsql/src/interfaces/libpq/fe-secure.c,v 1.96 2007/10/02 00:25:20 tgl Exp $
*
* NOTES
* [ Most of these notes are wrong/obsolete, but perhaps not all ]
@@ -136,6 +136,12 @@
#define ROOT_CRL_FILE "root.crl"
#endif
+#ifndef HAVE_ERR_SET_MARK
+/* These don't exist in OpenSSL before 0.9.8 */
+#define ERR_set_mark() ((void) 0)
+#define ERR_pop_to_mark() ((void) 0)
+#endif
+
#ifdef NOT_USED
static int verify_peer(PGconn *);
#endif