38
38
#ifdef PHP_WIN32
39
39
#include <string.h>
40
40
#include "config.w32.h"
41
- #undef WINDOWS
42
41
#undef strcasecmp
43
42
#undef strncasecmp
44
43
#define WINSOCK 1
@@ -1892,12 +1891,12 @@ PHP_FUNCTION(ldap_get_entries)
1892
1891
add_index_string (& tmp1 , num_attrib , attribute );
1893
1892
1894
1893
num_attrib ++ ;
1895
- #if (LDAP_API_VERSION > 2000 ) || defined(HAVE_ORALDAP ) || WINDOWS
1894
+ #if (LDAP_API_VERSION > 2000 ) || defined(HAVE_ORALDAP )
1896
1895
ldap_memfree (attribute );
1897
1896
#endif
1898
1897
attribute = ldap_next_attribute (ldap , ldap_result_entry , ber );
1899
1898
}
1900
- #if (LDAP_API_VERSION > 2000 ) || defined(HAVE_ORALDAP ) || WINDOWS
1899
+ #if (LDAP_API_VERSION > 2000 ) || defined(HAVE_ORALDAP )
1901
1900
if (ber != NULL ) {
1902
1901
ber_free (ber , 0 );
1903
1902
}
@@ -1910,7 +1909,7 @@ PHP_FUNCTION(ldap_get_entries)
1910
1909
} else {
1911
1910
add_assoc_null (& tmp1 , "dn" );
1912
1911
}
1913
- #if (LDAP_API_VERSION > 2000 ) || defined(HAVE_ORALDAP ) || WINDOWS
1912
+ #if (LDAP_API_VERSION > 2000 ) || defined(HAVE_ORALDAP )
1914
1913
ldap_memfree (dn );
1915
1914
#else
1916
1915
free (dn );
@@ -1948,7 +1947,7 @@ PHP_FUNCTION(ldap_first_attribute)
1948
1947
RETURN_FALSE ;
1949
1948
} else {
1950
1949
RETVAL_STRING (attribute );
1951
- #if (LDAP_API_VERSION > 2000 ) || defined(HAVE_ORALDAP ) || WINDOWS
1950
+ #if (LDAP_API_VERSION > 2000 ) || defined(HAVE_ORALDAP )
1952
1951
ldap_memfree (attribute );
1953
1952
#endif
1954
1953
}
@@ -1978,7 +1977,7 @@ PHP_FUNCTION(ldap_next_attribute)
1978
1977
}
1979
1978
1980
1979
if ((attribute = ldap_next_attribute (ld -> link , resultentry -> data , resultentry -> ber )) == NULL ) {
1981
- #if (LDAP_API_VERSION > 2000 ) || defined(HAVE_ORALDAP ) || WINDOWS
1980
+ #if (LDAP_API_VERSION > 2000 ) || defined(HAVE_ORALDAP )
1982
1981
if (resultentry -> ber != NULL ) {
1983
1982
ber_free (resultentry -> ber , 0 );
1984
1983
resultentry -> ber = NULL ;
@@ -1987,7 +1986,7 @@ PHP_FUNCTION(ldap_next_attribute)
1987
1986
RETURN_FALSE ;
1988
1987
} else {
1989
1988
RETVAL_STRING (attribute );
1990
- #if (LDAP_API_VERSION > 2000 ) || defined(HAVE_ORALDAP ) || WINDOWS
1989
+ #if (LDAP_API_VERSION > 2000 ) || defined(HAVE_ORALDAP )
1991
1990
ldap_memfree (attribute );
1992
1991
#endif
1993
1992
}
@@ -2034,12 +2033,12 @@ PHP_FUNCTION(ldap_get_attributes)
2034
2033
add_index_string (return_value , num_attrib , attribute );
2035
2034
2036
2035
num_attrib ++ ;
2037
- #if (LDAP_API_VERSION > 2000 ) || defined(HAVE_ORALDAP ) || WINDOWS
2036
+ #if (LDAP_API_VERSION > 2000 ) || defined(HAVE_ORALDAP )
2038
2037
ldap_memfree (attribute );
2039
2038
#endif
2040
2039
attribute = ldap_next_attribute (ld -> link , resultentry -> data , ber );
2041
2040
}
2042
- #if (LDAP_API_VERSION > 2000 ) || defined(HAVE_ORALDAP ) || WINDOWS
2041
+ #if (LDAP_API_VERSION > 2000 ) || defined(HAVE_ORALDAP )
2043
2042
if (ber != NULL ) {
2044
2043
ber_free (ber , 0 );
2045
2044
}
@@ -2107,7 +2106,7 @@ PHP_FUNCTION(ldap_get_dn)
2107
2106
text = ldap_get_dn (ld -> link , resultentry -> data );
2108
2107
if (text != NULL ) {
2109
2108
RETVAL_STRING (text );
2110
- #if (LDAP_API_VERSION > 2000 ) || defined(HAVE_ORALDAP ) || WINDOWS
2109
+ #if (LDAP_API_VERSION > 2000 ) || defined(HAVE_ORALDAP )
2111
2110
ldap_memfree (text );
2112
2111
#else
2113
2112
free (text );
@@ -2164,7 +2163,7 @@ PHP_FUNCTION(ldap_dn2ufn)
2164
2163
2165
2164
if (ufn != NULL ) {
2166
2165
RETVAL_STRING (ufn );
2167
- #if (LDAP_API_VERSION > 2000 ) || defined(HAVE_ORALDAP ) || WINDOWS
2166
+ #if (LDAP_API_VERSION > 2000 ) || defined(HAVE_ORALDAP )
2168
2167
ldap_memfree (ufn );
2169
2168
#endif
2170
2169
} else {
0 commit comments