From: Ruediger Pluem Date: Fri, 4 May 2007 11:11:26 +0000 (+0000) Subject: * Add extern "C" linkage to several headers to make it easier to use X-Git-Tag: 2.3.0~1820 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=56acf588e4e48022ccc498444bcec9cf6ca997fb;p=thirdparty%2Fapache%2Fhttpd.git * Add extern "C" linkage to several headers to make it easier to use them in C++ code. PR: 42286 Submitted by: Davi Arnaut Reviewed by: rpluem git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@535169 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/include/ap_listen.h b/include/ap_listen.h index a652128bd3e..b623495ba1c 100644 --- a/include/ap_listen.h +++ b/include/ap_listen.h @@ -30,6 +30,10 @@ #include "httpd.h" #include "http_config.h" +#ifdef __cplusplus +extern "C" { +#endif + typedef struct ap_listen_rec ap_listen_rec; typedef apr_status_t (*accept_function)(void **csd, ap_listen_rec *lr, apr_pool_t *ptrans); @@ -115,5 +119,9 @@ AP_INIT_TAKE1("SendBufferSize", ap_set_send_buffer_size, NULL, RSRC_CONF, \ AP_INIT_TAKE1("ReceiveBufferSize", ap_set_receive_buffer_size, NULL, \ RSRC_CONF, "Receive buffer size in bytes") +#ifdef __cplusplus +} +#endif + #endif /** @} */ diff --git a/include/ap_mpm.h b/include/ap_mpm.h index 107a8c08a9b..713f97d8ffb 100644 --- a/include/ap_mpm.h +++ b/include/ap_mpm.h @@ -28,6 +28,10 @@ #include "apr_thread_proc.h" +#ifdef __cplusplus +extern "C" { +#endif + /* The MPM, "multi-processing model" provides an abstraction of the interface with the OS for distributing incoming connections to @@ -179,5 +183,9 @@ typedef struct ap_exception_info_t { AP_DECLARE_HOOK(int,fatal_exception,(ap_exception_info_t *ei)) #endif /*AP_ENABLE_EXCEPTION_HOOK*/ +#ifdef __cplusplus +} +#endif + #endif /** @} */ diff --git a/include/ap_provider.h b/include/ap_provider.h index e54b9188faf..adfc69cad69 100644 --- a/include/ap_provider.h +++ b/include/ap_provider.h @@ -28,6 +28,10 @@ #include "ap_config.h" +#ifdef __cplusplus +extern "C" { +#endif + typedef struct { const char *provider_name; } ap_list_provider_names_t; @@ -74,5 +78,9 @@ AP_DECLARE(apr_array_header_t *) ap_list_provider_names(apr_pool_t *pool, const char *provider_group, const char *provider_version); +#ifdef __cplusplus +} +#endif + #endif /** @} */ diff --git a/include/util_cfgtree.h b/include/util_cfgtree.h index 78df416d2b8..58673f6e01c 100644 --- a/include/util_cfgtree.h +++ b/include/util_cfgtree.h @@ -28,6 +28,10 @@ #include "ap_config.h" +#ifdef __cplusplus +extern "C" { +#endif + typedef struct ap_directive_t ap_directive_t; /** @@ -83,5 +87,9 @@ AP_DECLARE_DATA extern ap_directive_t *ap_conftree; ap_directive_t *ap_add_node(ap_directive_t **parent, ap_directive_t *current, ap_directive_t *toadd, int child); +#ifdef __cplusplus +} +#endif + #endif /** @} */ diff --git a/include/util_ldap.h b/include/util_ldap.h index d6c034eebeb..f0dca264ac0 100644 --- a/include/util_ldap.h +++ b/include/util_ldap.h @@ -69,6 +69,10 @@ #define LDAP_DECLARE_DATA __declspec(dllimport) #endif +#ifdef __cplusplus +extern "C" { +#endif + /* * LDAP Connections */ @@ -323,6 +327,8 @@ apr_status_t util_ldap_cache_init(apr_pool_t *pool, util_ldap_state_t *st); * @deffunc char *util_ald_cache_display(apr_pool_t *pool, util_ldap_state_t *st) */ char *util_ald_cache_display(request_rec *r, util_ldap_state_t *st); - +#ifdef __cplusplus +} +#endif #endif /* APR_HAS_LDAP */ #endif /* UTIL_LDAP_H */