aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar Mark D. Roth <roth@google.com>2016-10-07 07:16:15 -0700
committerGravatar GitHub <noreply@github.com>2016-10-07 07:16:15 -0700
commite5c744d9850a763639b2e7001cf2487e1c76133b (patch)
tree5fac9070f244853795789e40e014efd84ee4be8d
parent824fbcf338c22e4bb5c757a19c7ed66b9d3603b6 (diff)
parent757e84ef1cfd50661cb8242debd7a7990448dde1 (diff)
Merge pull request #8307 from markdroth/header_fix
Fix C++ filter API header.
-rw-r--r--src/core/lib/iomgr/error.h8
-rw-r--r--src/cpp/common/channel_filter.h6
2 files changed, 9 insertions, 5 deletions
diff --git a/src/core/lib/iomgr/error.h b/src/core/lib/iomgr/error.h
index 7e2fd7a3bd..00ace8a7a9 100644
--- a/src/core/lib/iomgr/error.h
+++ b/src/core/lib/iomgr/error.h
@@ -40,6 +40,10 @@
#include <grpc/status.h>
#include <grpc/support/time.h>
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/// Opaque representation of an error.
/// Errors are refcounted objects that represent the result of an operation.
/// Ownership laws:
@@ -204,4 +208,8 @@ bool grpc_log_if_error(const char *what, grpc_error *error, const char *file,
#define GRPC_LOG_IF_ERROR(what, error) \
grpc_log_if_error((what), (error), __FILE__, __LINE__)
+#ifdef __cplusplus
+}
+#endif
+
#endif /* GRPC_CORE_LIB_IOMGR_ERROR_H */
diff --git a/src/cpp/common/channel_filter.h b/src/cpp/common/channel_filter.h
index 6f5af3dec3..ae32e02f69 100644
--- a/src/cpp/common/channel_filter.h
+++ b/src/cpp/common/channel_filter.h
@@ -42,6 +42,7 @@
#include <vector>
#include "src/core/lib/channel/channel_stack.h"
+#include "src/core/lib/security/context/security_context.h"
#include "src/core/lib/surface/channel_init.h"
#include "src/core/lib/transport/metadata_batch.h"
@@ -54,11 +55,6 @@
/// "name-of-filter", GRPC_SERVER_CHANNEL, INT_MAX, nullptr);
/// \endcode
-/// Forward declaration to avoid including the file
-/// "src/core/lib/security/context/security_context.h"
-struct grpc_client_security_context;
-struct grpc_server_security_context;
-
namespace grpc {
/// A C++ wrapper for the \c grpc_metadata_batch struct.