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

Commitc6b55be

Browse files
committed
Fix unused-variable warning on Windows.
Introduced in585bca3: msgid is not used in the Windows code path.Also adjust comments a tad (mostly to keep pgindent from messing it up).David Rowley
1 parentea8725a commitc6b55be

File tree

1 file changed

+9
-4
lines changed

1 file changed

+9
-4
lines changed

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

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3415,11 +3415,13 @@ ldapServiceLookup(const char *purl, PQconninfoOption *options,
34153415
intport=LDAP_DEF_PORT,
34163416
scope,
34173417
rc,
3418-
msgid,
34193418
size,
34203419
state,
34213420
oldstate,
34223421
i;
3422+
#ifndefWIN32
3423+
intmsgid;
3424+
#endif
34233425
boolfound_keyword;
34243426
char*url,
34253427
*hostname,
@@ -3564,11 +3566,13 @@ ldapServiceLookup(const char *purl, PQconninfoOption *options,
35643566

35653567
/*
35663568
* Perform an explicit anonymous bind.
3567-
* LDAP does not require that an anonymous bind is preformed explicitly,
3569+
*
3570+
* LDAP does not require that an anonymous bind is performed explicitly,
35683571
* but we want to distinguish between the case where LDAP bind does not
35693572
* succeed within PGLDAP_TIMEOUT seconds (return 2 to continue parsing
35703573
* the service control file) and the case where querying the LDAP server
35713574
* fails (return 1 to end parsing).
3575+
*
35723576
* Unfortunately there is no way of setting a timeout that works for
35733577
* both Windows and OpenLDAP.
35743578
*/
@@ -3581,7 +3585,7 @@ ldapServiceLookup(const char *purl, PQconninfoOption *options,
35813585
ldap_unbind(ld);
35823586
return2;
35833587
}
3584-
#else/* WIN32 */
3588+
#else/*!WIN32 */
35853589
/* in OpenLDAP, use the LDAP_OPT_NETWORK_TIMEOUT option */
35863590
if (ldap_set_option(ld,LDAP_OPT_NETWORK_TIMEOUT,&time)!=LDAP_SUCCESS)
35873591
{
@@ -3836,7 +3840,8 @@ ldapServiceLookup(const char *purl, PQconninfoOption *options,
38363840

38373841
return0;
38383842
}
3839-
#endif
3843+
3844+
#endif/* USE_LDAP */
38403845

38413846
#defineMAXBUFSIZE 256
38423847

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp