]> git.sur5r.net Git - openldap/blobdiff - include/ldif.h
comment away #undefs
[openldap] / include / ldif.h
index dd2b339193ec723426f90939b17008dd723ae97c..c24bb0a1526e9b44a2a6857ebf4650e5205abd1d 100644 (file)
@@ -13,9 +13,9 @@
 #ifndef _LDIF_H
 #define _LDIF_H
 
-#ifdef __cplusplus
-extern "C" {
-#endif
+#include <ldap_cdefs.h>
+
+LDAP_BEGIN_DECL
 
 #define LINE_WIDTH      76      /* maximum length of LDIF lines */
 
@@ -34,23 +34,14 @@ extern "C" {
  */
 #define LDIF_SIZE_NEEDED(tlen,vlen) \
     ((tlen) + 4 + LDIF_BASE64_LEN(vlen) \
-    + ((LDIF_BASE64_LEN(vlen) + tlen + 3) / LINE_WIDTH * 2 ))
-
-
-#ifdef NEEDPROTOS
-int str_parse_line( char *line, char **type, char **value, int *vlen);
-char * str_getline( char **next );
-void put_type_and_value( char **out, char *t, char *val, int vlen );
-char *ldif_type_and_value( char *type, char *val, int vlen );
-#else /* NEEDPROTOS */
-int str_parse_line();
-char * str_getline();
-void put_type_and_value();
-char *ldif_type_and_value();
-#endif /* NEEDPROTOS */
-
-#ifdef __cplusplus
-}
-#endif
+    + ((LDIF_BASE64_LEN(vlen) + (tlen) + 3) / LINE_WIDTH * 2 ))
+
+
+int str_parse_line LDAP_P(( char *line, char **type, char **value, int *vlen));
+char * str_getline LDAP_P(( char **next ));
+void put_type_and_value LDAP_P(( char **out, char *t, char *val, int vlen ));
+char *ldif_type_and_value LDAP_P(( char *type, char *val, int vlen ));
+
+LDAP_END_DECL
 
 #endif /* _LDIF_H */