File tree Expand file tree Collapse file tree 2 files changed +6
-14
lines changed Expand file tree Collapse file tree 2 files changed +6
-14
lines changed Original file line number Diff line number Diff line change 1111 *
1212 *
1313 * IDENTIFICATION
14- * $PostgreSQL: pgsql/src/interfaces/libpq/fe-secure.c,v 1.76 2006/04/27 00:36:34 momjian Exp $
14+ * $PostgreSQL: pgsql/src/interfaces/libpq/fe-secure.c,v 1.77 2006/04/27 00:53:58 momjian Exp $
1515 *
1616 * NOTES
1717 * [ Most of these notes are wrong/obsolete, but perhaps not all ]
@@ -1014,9 +1014,9 @@ SSLerrfree(char *buf)
10141014}
10151015
10161016/*
1017- * Return pointer to SSL object.
1017+ * Return pointer to OpenSSL object.
10181018 */
1019- SSL *
1019+ void *
10201020PQgetssl (PGconn * conn )
10211021{
10221022 if (!conn )
Original file line number Diff line number Diff line change 77 * Portions Copyright (c) 1996-2006, PostgreSQL Global Development Group
88 * Portions Copyright (c) 1994, Regents of the University of California
99 *
10- * $PostgreSQL: pgsql/src/interfaces/libpq/libpq-fe.h,v 1.126 2006/03/20 15:07:05 momjian Exp $
10+ * $PostgreSQL: pgsql/src/interfaces/libpq/libpq-fe.h,v 1.127 2006/04/27 00:53:58 momjian Exp $
1111 *
1212 *-------------------------------------------------------------------------
1313 */
@@ -28,11 +28,6 @@ extern "C"
2828 */
2929#include "postgres_ext.h"
3030
31- /* SSL type is needed here only to declare PQgetssl() */
32- #ifdef USE_SSL
33- #include <openssl/ssl.h>
34- #endif
35-
3631/* Application-visible enum types */
3732
3833typedef enum
@@ -271,12 +266,9 @@ extern int PQbackendPID(const PGconn *conn);
271266extern int PQclientEncoding (const PGconn * conn );
272267extern int PQsetClientEncoding (PGconn * conn , const char * encoding );
273268
274- #ifdef USE_SSL
275- /* Get the SSL structure associated with a connection */
276- extern SSL * PQgetssl (PGconn * conn );
277- #else
269+ /* Get the OpenSSL structure associated with a connection. Returns NULL for
270+ * unencrypted connections or if any other TLS library is in use. */
278271extern void * PQgetssl (PGconn * conn );
279- #endif
280272
281273/* Tell libpq whether it needs to initialize OpenSSL */
282274extern void PQinitSSL (int do_init );
You can’t perform that action at this time.
0 commit comments