pkgmgr_installer is set by pkgmgr_installer_receive_request() function
and Whether it is an upgrade request or not doesn't know by this function
Change-Id: I3282cd47b4dc27a6ef0d0675d422234f9c402e9f
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
struct pkgmgr_installer {
int request_type;
int move_type;
struct pkgmgr_installer {
int request_type;
int move_type;
char *pkgmgr_info;
char *session_id;
char *license_path;
char *pkgmgr_info;
char *session_id;
char *license_path;
+
+API int pkgmgr_installer_set_is_upgrade(pkgmgr_installer *pi, int is_upgrade) {
+ if (pi == NULL)
+ return -1;
+
+ pi->is_upgrade = is_upgrade;
+ return 0;
+}
int pkgmgr_installer_send_signals_for_uid(pkgmgr_installer *pi, uid_t uid,
const char *key, const char *val);
int pkgmgr_installer_send_signals_for_uid(pkgmgr_installer *pi, uid_t uid,
const char *key, const char *val);
+/**
+ * @brief This API sets is_upgrade_flag of given pkgmgr_installer.
+ *
+ * This API is for package-manager client application.\n
+ *
+ * @param[in]pi pointer to pkgmgr_installer
+ * @param[in]is_upgrade is_upgrade flag
+ * @return 0 if success, error code(<0) if fail\n
+*/
+int pkgmgr_installer_set_is_upgrade(pkgmgr_installer *pi, int is_upgrade);
+
#ifdef __cplusplus
}
#endif
#ifdef __cplusplus
}
#endif