]> git.pld-linux.org Git - packages/cyrus-sasl.git/blame - cyrus-sasl-get_fqhostname.patch
- add db 5.3 and 5.2 to the search list
[packages/cyrus-sasl.git] / cyrus-sasl-get_fqhostname.patch
CommitLineData
e46dcf5e
JR
1--- cyrus-sasl-2.1.25/lib/saslutil.c.orig 2011-10-21 13:59:59.354462366 +0200
2+++ cyrus-sasl-2.1.25/lib/saslutil.c 2011-10-21 14:10:55.849675881 +0200
3@@ -555,32 +555,44 @@
4 NULL, /* don't care abour service/port */
5 &hints,
6 &result) != 0) {
7- /* errno on Unix, WSASetLastError on Windows are already done by the function */
8- return (-1);
9+ if (abort_if_no_fqdn) {
10+ /* errno on Unix, WSASetLastError on Windows are already done by the function */
11+ return (-1);
12+ } else {
13+ goto LOWERCASE;
14+ }
15 }
16
17- if (abort_if_no_fqdn && (result == NULL || result->ai_canonname == NULL)) {
18+ if (result == NULL || result->ai_canonname == NULL) {
19 freeaddrinfo (result);
20+ if (abort_if_no_fqdn) {
21 #ifdef WIN32
22- WSASetLastError (WSANO_DATA);
23+ WSASetLastError (WSANO_DATA);
24 #elif defined(ENODATA)
25- errno = ENODATA;
26+ errno = ENODATA;
27 #elif defined(EADDRNOTAVAIL)
28- errno = EADDRNOTAVAIL;
29+ errno = EADDRNOTAVAIL;
30 #endif
31- return (-1);
32+ return (-1);
33+ } else {
34+ goto LOWERCASE;
35+ }
36 }
37
38- if (abort_if_no_fqdn && strchr (result->ai_canonname, '.') == NULL) {
39+ if (strchr (result->ai_canonname, '.') == NULL) {
40 freeaddrinfo (result);
41+ if (abort_if_no_fqdn) {
42 #ifdef WIN32
43- WSASetLastError (WSANO_DATA);
44+ WSASetLastError (WSANO_DATA);
45 #elif defined(ENODATA)
46- errno = ENODATA;
47+ errno = ENODATA;
48 #elif defined(EADDRNOTAVAIL)
49- errno = EADDRNOTAVAIL;
50+ errno = EADDRNOTAVAIL;
51 #endif
52- return (-1);
53+ return (-1);
54+ } else {
55+ goto LOWERCASE;
56+ }
57 }
58
59
This page took 0.025694 seconds and 4 git commands to generate.