]> git.sur5r.net Git - openldap/commitdiff
Fix prev commit, it was not Linux-only as it claimed to be.
authorQuanah Gibson-Mount <quanah@openldap.org>
Thu, 13 Aug 2009 20:58:53 +0000 (20:58 +0000)
committerQuanah Gibson-Mount <quanah@openldap.org>
Thu, 13 Aug 2009 20:58:53 +0000 (20:58 +0000)
libraries/libldap/os-ip.c

index d2d0fac434ebca374f86a3b72efd23bcf7ad4bb2..bd4596105d6fb47596fb6c5ff937283ff28a1f0f 100644 (file)
@@ -145,6 +145,10 @@ ldap_int_prepare_socket(LDAP *ld, int s, int proto )
                if ( ld->ld_options.ldo_keepalive_idle > 0 )
                {
 #ifdef TCP_KEEPIDLE
+/* AIX uses protocol numbers for everything besides SOL_SOCKET */
+#ifndef SOL_TCP
+#define        SOL_TCP IPPROTO_TCP
+#endif
                        if ( setsockopt( s, SOL_TCP, TCP_KEEPIDLE,
                                        (void*) &ld->ld_options.ldo_keepalive_idle,
                                        sizeof(ld->ld_options.ldo_keepalive_idle) ) == AC_SOCKET_ERROR )