Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commita54ea1f

Browse files
committed
Comment out check for substitution of private key file on Windows,
since st_ino can't be trusted on that platform. Per report from T.J.
1 parent8e4f407 commita54ea1f

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

‎src/interfaces/libpq/fe-secure.c

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
*
1212
*
1313
* IDENTIFICATION
14-
* $PostgreSQL: pgsql/src/interfaces/libpq/fe-secure.c,v 1.66 2005/01/08 22:51:15 tgl Exp $
14+
* $PostgreSQL: pgsql/src/interfaces/libpq/fe-secure.c,v 1.67 2005/01/10 00:37:12 tgl Exp $
1515
*
1616
* NOTES
1717
* [ Most of these notes are wrong/obsolete, but perhaps not all ]
@@ -768,8 +768,10 @@ static int
768768
client_cert_cb(SSL*ssl,X509**x509,EVP_PKEY**pkey)
769769
{
770770
charhomedir[MAXPGPATH];
771-
structstatbuf,
772-
buf2;
771+
structstatbuf;
772+
#ifndefWIN32
773+
structstatbuf2;
774+
#endif
773775
charfnbuf[MAXPGPATH];
774776
FILE*fp;
775777
PGconn*conn= (PGconn*)SSL_get_app_data(ssl);
@@ -831,13 +833,15 @@ client_cert_cb(SSL *ssl, X509 **x509, EVP_PKEY **pkey)
831833
fnbuf,pqStrerror(errno,sebuf,sizeof(sebuf)));
832834
return0;
833835
}
836+
#ifndefWIN32
834837
if (fstat(fileno(fp),&buf2)==-1||
835838
buf.st_dev!=buf2.st_dev||buf.st_ino!=buf2.st_ino)
836839
{
837840
printfPQExpBuffer(&conn->errorMessage,
838841
libpq_gettext("private key file \"%s\" changed during execution\n"),fnbuf);
839842
return0;
840843
}
844+
#endif
841845
if (PEM_read_PrivateKey(fp,pkey,cb,NULL)==NULL)
842846
{
843847
char*err=SSLerrmessage();

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp