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

Commit98876f0

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 parentfc72e94 commit98876f0

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
@@ -3378,11 +3378,13 @@ ldapServiceLookup(const char *purl, PQconninfoOption *options,
33783378
intport=LDAP_DEF_PORT,
33793379
scope,
33803380
rc,
3381-
msgid,
33823381
size,
33833382
state,
33843383
oldstate,
33853384
i;
3385+
#ifndefWIN32
3386+
intmsgid;
3387+
#endif
33863388
boolfound_keyword;
33873389
char*url,
33883390
*hostname,
@@ -3527,11 +3529,13 @@ ldapServiceLookup(const char *purl, PQconninfoOption *options,
35273529

35283530
/*
35293531
* Perform an explicit anonymous bind.
3530-
* LDAP does not require that an anonymous bind is preformed explicitly,
3532+
*
3533+
* LDAP does not require that an anonymous bind is performed explicitly,
35313534
* but we want to distinguish between the case where LDAP bind does not
35323535
* succeed within PGLDAP_TIMEOUT seconds (return 2 to continue parsing
35333536
* the service control file) and the case where querying the LDAP server
35343537
* fails (return 1 to end parsing).
3538+
*
35353539
* Unfortunately there is no way of setting a timeout that works for
35363540
* both Windows and OpenLDAP.
35373541
*/
@@ -3544,7 +3548,7 @@ ldapServiceLookup(const char *purl, PQconninfoOption *options,
35443548
ldap_unbind(ld);
35453549
return2;
35463550
}
3547-
#else/* WIN32 */
3551+
#else/*!WIN32 */
35483552
/* in OpenLDAP, use the LDAP_OPT_NETWORK_TIMEOUT option */
35493553
if (ldap_set_option(ld,LDAP_OPT_NETWORK_TIMEOUT,&time)!=LDAP_SUCCESS)
35503554
{
@@ -3799,7 +3803,8 @@ ldapServiceLookup(const char *purl, PQconninfoOption *options,
37993803

38003804
return0;
38013805
}
3802-
#endif
3806+
3807+
#endif/* USE_LDAP */
38033808

38043809
#defineMAXBUFSIZE 256
38053810

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp