From: SooChan Lim Date: Tue, 6 Sep 2022 07:43:38 +0000 (+0900) Subject: example: check if a input_method_context is null. X-Git-Tag: accepted/tizen/unified/20220908.124855~3 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=82fd81f9fb4a00b01ddbe79fb69813a3d7d07436;p=platform%2Fcore%2Fuifw%2Flibds-tizen.git example: check if a input_method_context is null. Change-Id: I284fec4336d6235e2f8c88985c8965a6448fd6e7 --- diff --git a/examples/tinyds-tdm.c b/examples/tinyds-tdm.c index 2108efc..a797ca2 100644 --- a/examples/tinyds-tdm.c +++ b/examples/tinyds-tdm.c @@ -2513,6 +2513,10 @@ add_new_input_method_context(struct tinyds_input_method *input_method, context->input = text_input; context->context = ds_tizen_input_method_create_context(input_method->input_method); + if (context->context == NULL) { + ds_err("ds_tizen_input_method_create_context() failed."); + return false; + } context->destroy.notify = context_handle_destroy; ds_tizen_input_method_context_add_destroy_listener(context->context,