Fix dlopen path in mediadb-update 76/61476/2 accepted/tizen/common/20160308.143241 accepted/tizen/ivi/20160308.102248 accepted/tizen/ivi/20160310.052642 accepted/tizen/mobile/20160308.102142 accepted/tizen/mobile/20160310.052538 accepted/tizen/tv/20160308.102158 accepted/tizen/tv/20160310.052600 accepted/tizen/wearable/20160308.102229 accepted/tizen/wearable/20160310.052616 submit/tizen/20160305.131859 submit/tizen/20160308.065510
authorMinje Ahn <minje.ahn@samsung.com>
Tue, 8 Mar 2016 06:50:58 +0000 (15:50 +0900)
committerMinje Ahn <minje.ahn@samsung.com>
Tue, 8 Mar 2016 06:51:48 +0000 (15:51 +0900)
Change-Id: Iaceb78c3c4c4385509a2575ee7cec48a8d396e84
Signed-off-by: Minje Ahn <minje.ahn@samsung.com>
packaging/media-server.spec
src/mediadb-update.c

index aad6f31..bd503d7 100755 (executable)
@@ -1,6 +1,6 @@
 Name:       media-server
 Summary:    A server for media content management
-Version:    0.2.69
+Version:    0.2.70
 Release:    0
 Group:      Multimedia/Service
 License:    Apache-2.0
index ef51158..b450dae 100755 (executable)
@@ -33,7 +33,6 @@
 #include "media-util.h"
 
 #include <tzplatform_config.h>
-#define CONFIG_PATH "/usr/etc/media-server-plugin"
 
 GMainLoop * mainloop = NULL;
 
@@ -73,25 +72,14 @@ static void __check_media_db(void)
        void *db_handle = NULL;
        char *err_msg = NULL;
        int ret = 0;
-       FILE *fp;
-       char buf[256] = {0, };
 
-       fp = fopen(CONFIG_PATH, "rt");
-       if (fp == NULL) {
-               printf("fp is NULL\n");
-               return;
-       }
-
-       if ( fgets (buf , 256 , fp) != NULL ) {
-               printf("so file : [%s]\n", buf);
-       }
-
-       fclose(fp);
-
-       funcHandle = dlopen(buf, RTLD_LAZY);
+       funcHandle = dlopen("/usr/lib/libmedia-content-plugin.so", RTLD_LAZY);
        if (funcHandle == NULL) {
-               printf("Error when open plug-in\n");
-               return;
+               funcHandle = dlopen("/usr/lib64/libmedia-content-plugin.so", RTLD_LAZY);
+               if (funcHandle == NULL) {
+                       printf("Error when open plug-in\n");
+                       return;
+               }
        }
 
        svc_connect                     = dlsym(funcHandle, "connect_db");