From f095db812dc9799df0031cece7f3c5b6f1eb5c4e Mon Sep 17 00:00:00 2001 From: Sangyoon Jang Date: Thu, 8 Dec 2016 17:23:59 +0900 Subject: [PATCH] Fix making gvariant with pkgtype Change-Id: Ia0a788428da444dfc63a4fbf643bae53fd1c7ec3 Signed-off-by: Sangyoon Jang --- client/src/pkgmgr.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/client/src/pkgmgr.c b/client/src/pkgmgr.c index f3d8ff5..feb8dd5 100644 --- a/client/src/pkgmgr.c +++ b/client/src/pkgmgr.c @@ -495,7 +495,8 @@ API int pkgmgr_client_usr_install(pkgmgr_client *pc, const char *pkg_type, g_variant_builder_unref(builder); ret = pkgmgr_client_connection_send_request(client, "install", - g_variant_new("(uss@as)", uid, pkgtype, pkg_path, args), + g_variant_new("(uss@as)", uid, pkgtype ? pkgtype : "", + pkg_path, args), &result); if (ret != PKGMGR_R_OK) { ERR("request failed: %d", ret); @@ -651,7 +652,8 @@ API int pkgmgr_client_usr_mount_install(pkgmgr_client *pc, const char *pkg_type, g_variant_builder_unref(builder); ret = pkgmgr_client_connection_send_request(client, "mount_install", - g_variant_new("(uss@as)", uid, pkgtype, pkg_path, args), + g_variant_new("(uss@as)", uid, pkgtype ? pkgtype : "", + pkg_path, args), &result); if (ret != PKGMGR_R_OK) { ERR("request failed: %d", ret); -- 2.7.4