]> git.sur5r.net Git - openldap/blobdiff - servers/ldapd/modrdn.c
Fix idl_firstid to return NOID when !(nids > 1) instead of when (nids == 1)
[openldap] / servers / ldapd / modrdn.c
index d3d939eeb53f4d33215c7279fc840e0d375a3501..1dfa005b7aee666d8bc8db72bf5926597b5c86b2 100644 (file)
  * is provided ``as is'' without express or implied warranty.
  */
 
+#include "portable.h"
+
 #include <stdio.h>
+
+#include <ac/socket.h>
+
 #include <quipu/commonarg.h>
 #include <quipu/attrvalue.h>
 #include <quipu/ds_error.h>
 #include <quipu/modifyrdn.h>
 #include <quipu/dap2.h>
 #include <quipu/dua.h>
-#include <sys/types.h>
-#include <sys/socket.h>
+
 #include "lber.h"
 #include "ldap.h"
 #include "common.h"
 
-#ifdef COMPAT20
-extern int     ldap_compat;
+#ifdef LDAP_COMPAT20
 #define MODRDNTAG      (ldap_compat == 20 ? OLD_LDAP_RES_MODRDN : LDAP_RES_MODRDN)
 #else
 #define MODRDNTAG      LDAP_RES_MODRDN
@@ -41,8 +44,6 @@ do_modrdn(
        int                     rc, deleteoldrdn;
        struct ds_modifyrdn_arg ma;
        static CommonArgs       common = default_common_args;
-       extern DN               ldap_str2dn();
-       extern RDN              ldap_str2rdn();
 
        Debug( LDAP_DEBUG_TRACE, "do_modrdn\n", 0, 0, 0 );