Index: doc/src/sgml/libpq.sgml
===================================================================
RCS file: /cvsroot/pgsql/doc/src/sgml/libpq.sgml,v
retrieving revision 1.279
diff -c -c -r1.279 libpq.sgml
*** doc/src/sgml/libpq.sgml	23 Mar 2009 01:45:29 -0000	1.279
--- doc/src/sgml/libpq.sgml	28 Mar 2009 01:17:21 -0000
***************
*** 6169,6179 ****
    </para>
  
    <para>
!    If you are using <acronym>SSL</> inside your application (in addition
!    to inside <application>libpq</application>), you can call
!    <function>PQinitSSL(int)</> with <literal>0</> to tell
!    <application>libpq</application> that the <acronym>SSL</> library
!    has already been initialized by your application.
     <!-- If this URL changes replace it with a URL to www.archive.org. -->
     See <ulink
     url="http://h71000.www7.hp.com/doc/83final/BA554_90007/ch04.html"></ulink>
--- 6169,6181 ----
    </para>
  
    <para>
!    If your application initializes <literal>libssl</> or
!    <literal>libcrypto</> libraries and <application>libpq</application>
!    is built with <acronym>SSL</> support, you should call
!    <function>PQinitSSL(0)</> to tell <application>libpq</application>
!    that the <literal>libssl</> and <literal>libcrypto</> libraries
!    have been initialized by your application so
!    <application>libpq</application> will not initialize those libraries.
     <!-- If this URL changes replace it with a URL to www.archive.org. -->
     See <ulink
     url="http://h71000.www7.hp.com/doc/83final/BA554_90007/ch04.html"></ulink>
Index: src/interfaces/libpq/fe-secure.c
===================================================================
RCS file: /cvsroot/pgsql/src/interfaces/libpq/fe-secure.c,v
retrieving revision 1.119
diff -c -c -r1.119 fe-secure.c
*** src/interfaces/libpq/fe-secure.c	28 Jan 2009 15:06:47 -0000	1.119
--- src/interfaces/libpq/fe-secure.c	28 Mar 2009 01:17:22 -0000
***************
*** 870,875 ****
--- 870,876 ----
  
  		if (ssl_open_connections++ == 0)
  		{
+ 			/* This is actually libcrypto, not libssl. */
  			/* These are only required for threaded SSL applications */
  			CRYPTO_set_id_callback(pq_threadidcallback);
  			CRYPTO_set_locking_callback(pq_lockingcallback);
***************
*** 934,939 ****
--- 935,941 ----
  
  		if (ssl_open_connections == 0)
  		{
+ 			/* This is actually libcrypto, not libssl. */
  			/* No connections left, unregister all callbacks */
  			CRYPTO_set_locking_callback(NULL);
  			CRYPTO_set_id_callback(NULL);
