tbm_module: donot print the error message 33/260733/1
authorSooChan Lim <sc1.lim@samsung.com>
Fri, 2 Jul 2021 02:22:31 +0000 (11:22 +0900)
committerSooChan Lim <sc1.lim@samsung.com>
Fri, 2 Jul 2021 02:45:51 +0000 (11:45 +0900)
Donot print the error message when the backend does not support
hal_tbm_bufmgr_alloc_surface.

Change-Id: Iaeb5a9dc5d0348e7ce4fe51c996a65951b02f29e

src/tbm_module.c

index e53f69c..5b8abb5 100644 (file)
@@ -701,8 +701,8 @@ tbm_module_alloc_surface_data(tbm_module *module, int width, int height, int for
                                                                                           0,
                                                                                           (hal_tbm_error *)error);
        if (!surface_data->hal_surface) {
-               TBM_ERR("hal_tbm_bufmgr_alloc_surface failed.");
-               *error = TBM_ERROR_INVALID_OPERATION;
+               if (*error != TBM_ERROR_NOT_SUPPORTED) // do not print the error message when it is not supported.
+                       TBM_ERR("hal_tbm_bufmgr_alloc_surface failed.");
                free(surface_data);
                return NULL;
        }