fix svace error
authorYoungjae Shin <yj99.shin@samsung.com>
Thu, 20 Feb 2020 05:46:36 +0000 (14:46 +0900)
committerYoungjae Shin <yj99.shin@samsung.com>
Wed, 18 Mar 2020 08:53:50 +0000 (17:53 +0900)
client/mdsc_register_mode.c
plugin/TestPluginAction.cpp

index cea8916b7824068a1133f6188ceda53ffdb611d6..011cf08911a36e20a3c60a81c2a92b093470397e 100644 (file)
@@ -23,7 +23,7 @@
 
 struct mds_action_handle {
        char *id;
-       char *action;
+       char *rule;
        char *value;
 };
 
@@ -59,7 +59,7 @@ static void _mdsc_free_action(gpointer data)
        struct mds_action_handle *action_data = data;
 
        free(action_data->id);
-       free(action_data->action);
+       free(action_data->rule);
        free(action_data->value);
        free(action_data);
 }
@@ -74,7 +74,7 @@ static GVariant* _mdsc_create_mode_data(modes_mode_h mode)
        while (NULL != it) {
                struct mds_action_handle *action_data = (struct mds_action_handle *)it->data;
                g_variant_builder_add(action_builder, MODES_DBUS_ACTION_SIG, action_data->id,
-                               action_data->action, action_data->value);
+                               action_data->rule, action_data->value);
                it = g_list_next(it);
        }
 
@@ -121,7 +121,7 @@ API modes_action_h modes_create_action(const char *name, const char *value)
        action = malloc(sizeof(struct mds_action_handle));
        RETV_IF(NULL == action, NULL);
 
-       action->action = strdup(name);
+       action->rule = strdup(name);
        action->value = strdup(value);
        action->id = NULL;
 
index c88fa888782282e6c7db86b275aad106d0b06f7d..9b86b2e55a7affe191c62ed0b83edd7b2fecc01a 100644 (file)
@@ -22,7 +22,7 @@
 MODES_NAMESPACE_USE;
 
 TestPluginAction::TestPluginAction(const std::string &name)
-       : PluginAction(name)
+       : PluginAction(name), cb(nullptr), cbData(nullptr)
 {
 }