Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 40f32f3

Browse files
committed
Add conditional inclusion of <com_err.h> to support old 'heimdal'
version of Kerberos. Per report from Reinhard Max.
1 parent 2ec1aa4 commit 40f32f3

File tree

2 files changed

+10
-2
lines changed

2 files changed

+10
-2
lines changed

src/backend/libpq/auth.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $PostgreSQL: pgsql/src/backend/libpq/auth.c,v 1.121 2004/12/31 21:59:50 pgsql Exp $
11+
* $PostgreSQL: pgsql/src/backend/libpq/auth.c,v 1.122 2005/01/12 21:37:53 tgl Exp $
1212
*
1313
*-------------------------------------------------------------------------
1414
*/
@@ -150,6 +150,10 @@ pg_krb4_recvauth(Port *port)
150150
*/
151151

152152
#include <krb5.h>
153+
/* Some old versions of Kerberos do not include <com_err.h> in <krb5.h> */
154+
#if !defined(__COM_ERR_H) && !defined(__COM_ERR_H__)
155+
#include <com_err.h>
156+
#endif
153157

154158
/*
155159
* pg_an_to_ln -- return the local name corresponding to an authentication

src/interfaces/libpq/fe-auth.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
* exceed INITIAL_EXPBUFFER_SIZE (currently 256 bytes).
1111
*
1212
* IDENTIFICATION
13-
* $PostgreSQL: pgsql/src/interfaces/libpq/fe-auth.c,v 1.98 2005/01/04 23:18:25 tgl Exp $
13+
* $PostgreSQL: pgsql/src/interfaces/libpq/fe-auth.c,v 1.99 2005/01/12 21:37:54 tgl Exp $
1414
*
1515
*-------------------------------------------------------------------------
1616
*/
@@ -243,6 +243,10 @@ pg_krb4_sendauth(char *PQerrormsg, int sock,
243243
*/
244244

245245
#include <krb5.h>
246+
/* Some old versions of Kerberos do not include <com_err.h> in <krb5.h> */
247+
#if !defined(__COM_ERR_H) && !defined(__COM_ERR_H__)
248+
#include <com_err.h>
249+
#endif
246250

247251
/*
248252
* pg_an_to_ln -- return the local name corresponding to an authentication

0 commit comments

Comments
 (0)