From c6380561ed110686a5865ced9855653ae03280e3 Mon Sep 17 00:00:00 2001 From: Sangyoon Jang Date: Tue, 25 Jul 2017 13:32:18 +0900 Subject: [PATCH] Add a new move type PM_MOVE_TO_EXTENDED A new move type PM_MOVE_TO_EXTENDED is added to move package to extended storage. Change-Id: I5e7ba0be5a1c1b2444dcd3a7fe64396800761653 Signed-off-by: Sangyoon Jang --- client/include/package-manager.h | 3 ++- client/src/pkgmgr.c | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/client/include/package-manager.h b/client/include/package-manager.h index 52a486a..a7709e0 100644 --- a/client/include/package-manager.h +++ b/client/include/package-manager.h @@ -209,6 +209,7 @@ typedef enum { typedef enum { PM_MOVE_TO_INTERNAL = 0, PM_MOVE_TO_SDCARD = 1, + PM_MOVE_TO_EXTENDED = 2, } pkgmgr_move_type; typedef enum { @@ -394,7 +395,7 @@ int pkgmgr_client_usr_uninstall(pkgmgr_client *pc, const char *pkg_type, * @param[in] pc pkgmgr_client * @param[in] pkg_type package type * @param[in] pkgid application package id - * @param[in] move_type PM_MOVE_TO_INTERNAL or PM_MOVE_TO_SDCARD + * @param[in] move_type move type * @param[in] mode installation mode - PM_DEFAULT, PM_QUIET * @param[in] event_cb user callback * @param[in] data user data diff --git a/client/src/pkgmgr.c b/client/src/pkgmgr.c index f940516..babdd8c 100644 --- a/client/src/pkgmgr.c +++ b/client/src/pkgmgr.c @@ -719,7 +719,7 @@ API int pkgmgr_client_usr_move(pkgmgr_client *pc, const char *pkg_type, } if ((move_type < PM_MOVE_TO_INTERNAL) || - (move_type > PM_MOVE_TO_SDCARD)) + (move_type > PM_MOVE_TO_EXTENDED)) return PKGMGR_R_EINVAL; if (client->pc_type != PC_REQUEST) { @@ -1607,7 +1607,7 @@ API int pkgmgr_client_usr_request_service( case PM_REQUEST_MOVE: tryvm_if(pkgid == NULL, ret = PKGMGR_R_EINVAL, "pkgid is NULL\n"); tryvm_if(pc == NULL, ret = PKGMGR_R_EINVAL, "pc is NULL\n"); - tryvm_if((service_mode < PM_MOVE_TO_INTERNAL) || (service_mode > PM_MOVE_TO_SDCARD), ret = PKGMGR_R_EINVAL, "service_mode is wrong\n"); + tryvm_if((service_mode < PM_MOVE_TO_INTERNAL) || (service_mode > PM_MOVE_TO_EXTENDED), ret = PKGMGR_R_EINVAL, "service_mode is wrong\n"); ret = __move_pkg_process(pc, pkgid, pkg_type, uid, (pkgmgr_move_type)service_mode, event_cb, data); break; -- 2.7.4