/*Free Mime*/
if (appcontrol->mime)
free((void *)appcontrol->mime);
+ if (appcontrol->privileges)
+ g_list_free_full(appcontrol->privileges, free);
free((void *)appcontrol);
}
free((void *)privilege);
}
+static void __ps_free_appdefined_privilege(gpointer data)
+{
+ appdefined_privilege_x *privilege = (appdefined_privilege_x *)data;
+ if (privilege == NULL)
+ return;
+ if (privilege->type)
+ free((void *)privilege->type);
+ if (privilege->value)
+ free((void *)privilege->value);
+ if (privilege->license)
+ free((void *)privilege->license);
+ free((void *)privilege);
+}
+
static void __ps_free_datacontrol(gpointer data)
{
datacontrol_x *datacontrol = (datacontrol_x *)data;
if (datacontrol->trusted)
free((void *)datacontrol->trusted);
if (datacontrol->privileges)
- g_list_free_full(datacontrol->privileges, __ps_free_privilege);
+ g_list_free_full(datacontrol->privileges, free);
free((void *)datacontrol);
}
free((void *)package->external_path);
if (package->support_mode)
free((void *)package->support_mode);
+ if (package->use_system_certs)
+ free((void *)package->use_system_certs);
/*Free Icon*/
g_list_free_full(package->icon, __ps_free_icon);
g_list_free_full(package->license, __ps_free_license);
/*Free Privileges*/
g_list_free_full(package->privileges, __ps_free_privilege);
+ /*Free AppDefined Privileges*/
+ g_list_free_full(package->appdefined_privileges,
+ __ps_free_appdefined_privilege);
+ /*Free Providing AppDefined Privileges*/
+ g_list_free_full(package->provides_appdefined_privileges,
+ __ps_free_appdefined_privilege);
/*Free Application*/
g_list_free_full(package->application, __ps_free_application);
/*Free Compatibility*/