modifying null check in plugin app install 90/185290/1 accepted/tizen/unified/20180730.142014 submit/tizen/20180727.083824
authormanish.r <manish.r@samsung.com>
Fri, 27 Jul 2018 08:09:50 +0000 (13:39 +0530)
committermanish.r <manish.r@samsung.com>
Fri, 27 Jul 2018 08:36:44 +0000 (14:06 +0530)
Change-Id: I6c6c41c8733865537f0a863adda8aa154f4ccb15
Signed-off-by: manish.r <manish.r@samsung.com>
src/default_plugin_appcmd.c [changed mode: 0644->0755]

old mode 100644 (file)
new mode 100755 (executable)
index 78b2b4f..1c7204d
@@ -81,8 +81,8 @@ static int appcmd_install_gen_shellcmd(appcmd_info* p_info) {
     if (type != NULL && pkgpath != NULL && pkgid != NULL && teppath != NULL) {
                D("args: type=%s, pkgpath=%s, pkgid=%s, teppath=%s\n", type, pkgpath, pkgid, teppath);
 
-               if (strncmp(pkgid, "null", 4) == 0) {
-                       if (strncmp(teppath, "null", 4) == 0) {
+               if (strncmp(pkgid, "\\n\\u\\l\\l", 8) == 0) {
+                       if (strncmp(teppath, "\\n\\u\\l\\l", 8) == 0) {
                                /* Normal install case */
                                snprintf(buf, len, "pkgcmd -i -q -t %s -p %s -G", type, pkgpath);
                        } else {
@@ -93,7 +93,7 @@ static int appcmd_install_gen_shellcmd(appcmd_info* p_info) {
                        /* Re-install case */
                        snprintf(buf, len, "pkgcmd -r -q -t %s -n %s", type, pkgid);
                }
-
+               D("buf=%s\n", buf);
                free(type);
                free(pkgpath);
                free(pkgid);