Modify sqlite3 open option and etc. 86/69886/1
authorMinje Ahn <minje.ahn@samsung.com>
Tue, 17 May 2016 07:52:28 +0000 (16:52 +0900)
committerMinje Ahn <minje.ahn@samsung.com>
Tue, 17 May 2016 07:52:28 +0000 (16:52 +0900)
Change-Id: Ib85c176dcf1081cbccd7496e6900ddf9fcef3ada
Signed-off-by: Minje Ahn <minje.ahn@samsung.com>
lib/media-util-db.c
packaging/media-server.spec
src/common/media-common-system.c
src/scanner-v2/media-scanner-scan-v2.c
src/server/media-server-device-block.c

index 3ccb635..7a7ed1a 100755 (executable)
@@ -115,7 +115,7 @@ static int __media_db_connect_db_with_handle(sqlite3 **db_handle, uid_t uid, boo
        if (need_write) {
                ret = db_util_open_with_options(db_info, db_handle, SQLITE_OPEN_READWRITE | SQLITE_OPEN_CREATE, NULL);
        } else {
-               ret = db_util_open_with_options(db_info, db_handle, SQLITE_OPEN_READWRITE, NULL);
+               ret = db_util_open_with_options(db_info, db_handle, SQLITE_OPEN_READONLY, NULL);
        }
        MS_SAFE_FREE(db_info);
        if (SQLITE_OK != ret) {
index 319171f..9221396 100755 (executable)
@@ -1,6 +1,6 @@
 Name:       media-server
 Summary:    A server for media content management
-Version:    0.2.81
+Version:    0.2.82
 Release:    0
 Group:      Multimedia/Service
 License:    Apache-2.0
index d9ebdbd..280665b 100755 (executable)
@@ -441,9 +441,9 @@ static int __ms_gdbus_get_uid(const char *dest, const char *path, const char *in
        while (g_variant_iter_loop(iter, "(uso)", &val_int, &val_str, &val_str2)) {
                result++;
                MS_DBG("(%d)th block device information", result);
-               MS_DBG("\tType(%d)", val_int);
-               MS_DBG("\tdevnode(%s)", val_str);
-               MS_DBG("\tsyspath(%s)", val_str2);
+               MS_DBG("\tUID(%d)", val_int);
+               MS_DBG("\tNAME(%s)", val_str);
+               MS_DBG("\tPATH(%s)", val_str2);
                *uid = (uid_t) val_int;
                MS_SAFE_FREE(val_str);
                MS_SAFE_FREE(val_str2);
index ec0d909..76f1896 100755 (executable)
@@ -1304,7 +1304,6 @@ SCAN_DONE:
                        goto _POWEROFF;
                }
 
-
 NEXT:
                /*Active flush */
                malloc_trim(0);
index 0782595..909f668 100755 (executable)
@@ -99,7 +99,6 @@ int ms_usb_insert_handler(const char *mount_path, const char *mount_uuid)
                        }
                        scan_type = MS_SCAN_PART;
                        ms_set_storage_validity(handle, mount_uuid, 1, uid);
-
                        if (ms_set_storage_scan_status(handle, uuid, MEDIA_SCAN_PREPARE, uid) != MS_MEDIA_ERR_NONE) {
                                MS_DBG_ERR("ms_set_storage_scan_status failed");
                        }