From c0ed509d93d2f265cb157468214d328ac4e26d03 Mon Sep 17 00:00:00 2001 From: yang-g Date: Wed, 9 Dec 2015 08:48:08 -0800 Subject: Add test for un-resolvable target --- src/core/surface/channel_create.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src') diff --git a/src/core/surface/channel_create.c b/src/core/surface/channel_create.c index aceb932742..fe7e1072ac 100644 --- a/src/core/surface/channel_create.c +++ b/src/core/surface/channel_create.c @@ -218,6 +218,9 @@ grpc_channel *grpc_insecure_channel_create(const char *target, GRPC_CHANNEL_INTERNAL_REF(f->master, "subchannel_factory"); resolver = grpc_resolver_create(target, &f->base); if (!resolver) { + GRPC_CHANNEL_INTERNAL_UNREF(&exec_ctx, f->master, "subchannel_factory"); + grpc_subchannel_factory_unref(&exec_ctx, &f->base); + grpc_exec_ctx_finish(&exec_ctx); return NULL; } -- cgit v1.2.3