While upgrading packages, the instance's update period doesn't updated correctly.
This patch will apply the new update period.
But if the instance's update period is changed manually, (that is not same with in the XML),
the master will not touch it.
Only if the period is same with orignal value in the old XML, will be updated to the new value.
Change-Id: I4e8e9f8a104a3010b6261ab77770960463051c84
extern void *instance_del_data(struct inst_info *inst, const char *tag);
extern void *instance_get_data(struct inst_info *inst, const char *tag);
+extern void instance_reload_period(struct inst_info *inst, double period);
/* End of a file */
Name: data-provider-master
Summary: Master service provider for liveboxes
-Version: 0.41.0
+Version: 0.41.1
Release: 1
Group: HomeTF/Livebox
License: Flora
return ECORE_CALLBACK_CANCEL;
}
+HAPI void instance_reload_period(struct inst_info *inst, double period)
+{
+ inst->lb.period = period;
+}
+
HAPI int instance_set_period(struct inst_info *inst, double period)
{
struct packet *packet;
unsigned int size_type;
int width;
int height;
+ double old_period;
DbgPrint("Already exists, try to update it\n");
+ old_period = info->lb.period;
+
group_del_livebox(info->lbid);
package_clear_fault(info);
height = instance_lb_height(inst);
size_type = livebox_service_size_type(width, height);
if (info->lb.size_list & size_type) {
+ if (instance_period(inst) == old_period) {
+ instance_reload_period(inst, package_period(info));
+ }
instance_reload(inst, INSTANCE_DESTROY_UPGRADE);
} else {
instance_destroy(inst, INSTANCE_DESTROY_UNINSTALL);
s_info.destroy_handler =
ecore_event_handler_add(ECORE_X_EVENT_WINDOW_DESTROY,
destroy_cb, NULL);
- if (!s_info.create_handler) {
+ if (!s_info.destroy_handler) {
ErrPrint("Failed to add destroy event handler\n");
ecore_event_handler_del(s_info.create_handler);
s_info.create_handler = NULL;