diff --git a/include/grpc++/channel_interface.h b/include/grpc++/channel_interface.h index 4d48974e691..e86a83bc45b 100644 --- a/include/grpc++/channel_interface.h +++ b/include/grpc++/channel_interface.h @@ -34,6 +34,8 @@ #ifndef GRPCXX_CHANNEL_INTERFACE_H #define GRPCXX_CHANNEL_INTERFACE_H +#include + #include #include @@ -47,7 +49,9 @@ class CompletionQueue; class RpcMethod; class CallInterface; -class ChannelInterface : public CallHook { +class ChannelInterface + : public CallHook, + public std::enable_shared_from_this { public: virtual ~ChannelInterface() {} diff --git a/src/cpp/client/channel.h b/src/cpp/client/channel.h index 46009d20bad..cd239247c82 100644 --- a/src/cpp/client/channel.h +++ b/src/cpp/client/channel.h @@ -51,7 +51,6 @@ class Credentials; class StreamContextInterface; class Channel GRPC_FINAL : public GrpcLibrary, - public std::enable_shared_from_this, public ChannelInterface { public: Channel(const grpc::string& target, grpc_channel* c_channel);