From: Minje Ahn Date: Wed, 10 Jun 2015 06:17:33 +0000 (+0900) Subject: Remove drm source code. X-Git-Tag: submit/tizen/20150611.012456~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F72%2F40872%2F2;p=platform%2Fcore%2Fmultimedia%2Flibmedia-service.git Remove drm source code. Change-Id: Iacd86644c667db15d0a44cfe2b924c8c17efa1a7 Signed-off-by: Minje Ahn --- diff --git a/CMakeLists.txt b/CMakeLists.txt index 16c5531..cff6c21 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -53,7 +53,7 @@ EXEC_PROGRAM("${UNAME}" ARGS "-m" OUTPUT_VARIABLE "ARCH") INCLUDE(FindPkgConfig) -pkg_check_modules(pkgs REQUIRED glib-2.0 dlog sqlite3 db-util libexif mm-common mm-fileinfo media-thumbnail libmedia-utils aul uuid vconf drm-client) +pkg_check_modules(pkgs REQUIRED glib-2.0 dlog sqlite3 db-util libexif mm-common mm-fileinfo media-thumbnail libmedia-utils aul uuid vconf) FOREACH(flag ${pkgs_CFLAGS}) SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} ${flag}") diff --git a/include/media-svc-types.h b/include/media-svc-types.h index 0acf14e..786631a 100755 --- a/include/media-svc-types.h +++ b/include/media-svc-types.h @@ -44,7 +44,7 @@ typedef enum{ MEDIA_SVC_MEDIA_TYPE_VIDEO = 1, /**< Video Content*/ MEDIA_SVC_MEDIA_TYPE_SOUND = 2, /**< Sound Content like Ringtone*/ MEDIA_SVC_MEDIA_TYPE_MUSIC = 3, /**< Music Content like mp3*/ - MEDIA_SVC_MEDIA_TYPE_OTHER = 4, /**< Invalid Content*/ + MEDIA_SVC_MEDIA_TYPE_OTHER = 4, /**< Not media Content*/ }media_svc_media_type_e; #endif /*_MEDIA_SVC_TYPES_H_*/ diff --git a/packaging/libmedia-service.spec b/packaging/libmedia-service.spec old mode 100755 new mode 100644 index 2bf99a6..9a8e217 --- a/packaging/libmedia-service.spec +++ b/packaging/libmedia-service.spec @@ -1,9 +1,9 @@ Name: libmedia-service Summary: Media information service library for multimedia applications -Version: 0.2.47 +Version: 0.2.48 Release: 3 Group: System/Libraries -License: Apache License, Version 2.0 +License: Apache-2.0 and public domain Source0: %{name}-%{version}.tar.gz Source1001: libmedia-service.manifest @@ -20,13 +20,12 @@ BuildRequires: pkgconfig(sqlite3) BuildRequires: pkgconfig(db-util) BuildRequires: pkgconfig(mm-fileinfo) BuildRequires: pkgconfig(media-thumbnail) -BuildRequires: pkgconfig(drm-client) BuildRequires: pkgconfig(libmedia-utils) BuildRequires: pkgconfig(uuid) BuildRequires: pkgconfig(libtzplatform-config) %description -Media information service library for multimedia applications +Media information service library for multimedia applications. %package devel Summary: Media information service library for multimedia applications. (development) @@ -37,12 +36,11 @@ Requires: %{name} = %{version}-%{release} Media information service library for multimedia applications. (development files) %prep -%setup -q +%setup -q cp %{SOURCE1001} . - %build -%cmake . +%cmake . make %{?jobs:-j%jobs} %install diff --git a/plugin/media-content-plugin.c b/plugin/media-content-plugin.c index a4dc19d..bc2a1da 100755 --- a/plugin/media-content-plugin.c +++ b/plugin/media-content-plugin.c @@ -614,7 +614,7 @@ int update_end(uid_t uid) int ret = MEDIA_SVC_PLUGIN_ERROR_NONE; ret = thumbnail_request_extract_all_thumbs(uid); - if (ret < 0) { + if(ret < 0) { return MEDIA_SVC_PLUGIN_ERROR; } @@ -631,7 +631,7 @@ int send_dir_update_noti(void * handle, const char *dir_path, char **err_msg) } ret = media_svc_send_dir_update_noti(handle, dir_path); - if (ret < 0) { + if(ret < 0) { __set_error_message(ret, err_msg); return MEDIA_SVC_PLUGIN_ERROR; } diff --git a/src/common/media-svc-media-folder.c b/src/common/media-svc-media-folder.c index ae0128f..0a2e741 100755 --- a/src/common/media-svc-media-folder.c +++ b/src/common/media-svc-media-folder.c @@ -69,11 +69,7 @@ int _media_svc_append_folder(sqlite3 *handle, media_svc_storage_type_e storage_t MEDIA_SVC_DB_TABLE_FOLDER, folder_id, path_name, folder_name, storage_type, modified_date, folder_name_pinyin); ret = _media_svc_sql_query(handle, sql, uid); sqlite3_free(sql); - if (ret != SQLITE_OK) { - media_svc_error("failed to insert folder"); - return MS_MEDIA_ERR_DB_INTERNAL; - } - + SAFE_FREE(folder_name_pinyin); return ret; @@ -91,10 +87,6 @@ int _media_svc_update_folder_modified_time_by_folder_uuid(sqlite3 *handle, const if(!stack_query) { ret = _media_svc_sql_query(handle, sql, uid); sqlite3_free(sql); - if (ret != SQLITE_OK) { - media_svc_error("failed to update folder"); - return MS_MEDIA_ERR_DB_INTERNAL; - } } else { _media_svc_sql_query_add(&g_media_svc_move_item_query_list, &sql); } @@ -144,10 +136,6 @@ int _media_svc_update_folder_table(sqlite3 *handle, uid_t uid) ret = _media_svc_sql_query(handle, sql, uid); sqlite3_free(sql); - if (ret != SQLITE_OK) { - media_svc_error("failed to delete folder item"); - return MS_MEDIA_ERR_DB_INTERNAL; - } - return MS_MEDIA_ERR_NONE; + return ret; } diff --git a/src/common/media-svc-media.c b/src/common/media-svc-media.c index fbfd0ab..1712a6d 100755 --- a/src/common/media-svc-media.c +++ b/src/common/media-svc-media.c @@ -337,8 +337,11 @@ int _media_svc_insert_item_with_data(sqlite3 *handle, media_svc_content_info_s * content_info->media_meta.description_pinyin ); - if (burst_id) sqlite3_free(burst_id); - burst_id = NULL; + if (burst_id) + { + sqlite3_free(burst_id); + burst_id = NULL; + } if(!stack_query) { ret = _media_svc_sql_query(handle, sql, uid); diff --git a/src/common/media-svc-util.c b/src/common/media-svc-util.c index a2ac856..7a2892e 100755 --- a/src/common/media-svc-util.c +++ b/src/common/media-svc-util.c @@ -665,13 +665,12 @@ int _media_svc_get_file_time(const char *full_path) } int _media_svc_set_media_info(media_svc_content_info_s *content_info, media_svc_storage_type_e storage_type, - const char *path, media_svc_media_type_e *media_type, bool refresh, drm_content_info_s **drm_contentInfo) + const char *path, media_svc_media_type_e *media_type, bool refresh) { int ret = MS_MEDIA_ERR_NONE; char * media_uuid = NULL; char * file_name = NULL; struct stat st; - drm_bool_type_e drm_type = DRM_FALSE; char mime_type[256] = {0}; ret = __media_svc_malloc_and_strncpy(&content_info->path, path); @@ -754,16 +753,13 @@ int _media_svc_set_media_info(media_svc_content_info_s *content_info, media_svc_ SAFE_FREE(file_name); media_svc_retv_del_if(ret != MS_MEDIA_ERR_NONE, ret, content_info); - /* if the file is DRM file, drm_type value is DRM_TRUE(1). - if drm_contentinfo is not NULL, the file is OMA DRM.*/ - ret = _media_svc_get_mime_type(path, mime_type, &drm_type, drm_contentInfo); + ret = _media_svc_get_mime_type(path, mime_type); if (ret < 0) { media_svc_error("media_svc_get_mime_type failed : %d (%s)", ret, path); return MS_MEDIA_ERR_INVALID_PARAMETER; } media_svc_error("mime [%s]", mime_type); - content_info->is_drm = drm_type; ret = _media_svc_get_media_type(path, mime_type, media_type); media_svc_retv_if(ret != MS_MEDIA_ERR_NONE, ret); @@ -972,7 +968,7 @@ int _media_svc_extract_image_metadata(media_svc_content_info_s *content_info, me return MS_MEDIA_ERR_NONE; } -int _media_svc_extract_media_metadata(sqlite3 *handle, media_svc_content_info_s *content_info, media_svc_media_type_e media_type, drm_content_info_s *drm_contentInfo, uid_t uid) +int _media_svc_extract_media_metadata(sqlite3 *handle, media_svc_content_info_s *content_info, media_svc_media_type_e media_type, uid_t uid) { MMHandleType content = 0; MMHandleType tag = 0; @@ -989,88 +985,6 @@ int _media_svc_extract_media_metadata(sqlite3 *handle, media_svc_content_info_s int album_id = 0; double gps_value = 0.0; int ret = MS_MEDIA_ERR_NONE; - char *path = content_info->path; - -#ifdef __SUPPORT_DRM - /*To do - code for DRM content*/ - if (content_info->is_drm) { - drm_file_type_e drm_file_type; - - ret = drm_get_file_type(path, &drm_file_type); - if (ret < 0) { - media_svc_error("drm_get_file_type falied : %d", ret); - drm_file_type = DRM_TYPE_UNDEFINED; - } - - /* if drm_contentinfo is not NULL, the file is OMA DRM.*/ - if (drm_contentInfo != NULL) { - if (drm_file_type == DRM_TYPE_OMA_V1) { - if (strlen(drm_contentInfo->title) > 0) { - ret = __media_svc_malloc_and_strncpy(&content_info->media_meta.title, drm_contentInfo->title); - if(ret != MS_MEDIA_ERR_NONE) - media_svc_error("strcpy error"); - extracted_field |= MEDIA_SVC_EXTRACTED_FIELD_TITLE; - } - - if (strlen(drm_contentInfo->description) > 0) { - ret = __media_svc_malloc_and_strncpy(&content_info->media_meta.description, drm_contentInfo->description); - if(ret != MS_MEDIA_ERR_NONE) - media_svc_error("strcpy error"); - extracted_field |= MEDIA_SVC_EXTRACTED_FIELD_DESC; - } - } else if (drm_file_type == DRM_TYPE_OMA_V2) { - if (strlen(drm_contentInfo->title) > 0) { - ret = __media_svc_malloc_and_strncpy(&content_info->media_meta.title, drm_contentInfo->title); - if(ret != MS_MEDIA_ERR_NONE) - media_svc_error("strcpy error"); - extracted_field |= MEDIA_SVC_EXTRACTED_FIELD_TITLE; - } - - if (strlen(drm_contentInfo->description) > 0) { - ret = __media_svc_malloc_and_strncpy(&content_info->media_meta.description, drm_contentInfo->description); - if(ret != MS_MEDIA_ERR_NONE) - media_svc_error("strcpy error"); - extracted_field |= MEDIA_SVC_EXTRACTED_FIELD_DESC; - } - - if (strlen(drm_contentInfo->copyright) > 0) { - ret = __media_svc_malloc_and_strncpy(&content_info->media_meta.copyright, drm_contentInfo->copyright); - if(ret != MS_MEDIA_ERR_NONE) - media_svc_error("strcpy error"); - extracted_field |= MEDIA_SVC_EXTRACTED_FIELD_COPYRIGHT; - } - - if (strlen(drm_contentInfo->author) > 0) { - ret = __media_svc_malloc_and_strncpy(&content_info->media_meta.composer, drm_contentInfo->author); - if(ret != MS_MEDIA_ERR_NONE) - media_svc_error("strcpy error"); - ret = __media_svc_malloc_and_strncpy(&content_info->media_meta.artist, drm_contentInfo->author); - if(ret != MS_MEDIA_ERR_NONE) - media_svc_error("strcpy error"); - - extracted_field |= MEDIA_SVC_EXTRACTED_FIELD_AUTHOR; - extracted_field |= MEDIA_SVC_EXTRACTED_FIELD_ARTIST; - } - } - - if (!(extracted_field & MEDIA_SVC_EXTRACTED_FIELD_TITLE)) { - title = _media_svc_get_title_from_filepath(path); - if (title) { - ret = __media_svc_malloc_and_strncpy(&content_info->media_meta.title, title); - SAFE_FREE(title); - if(ret != MS_MEDIA_ERR_NONE) - media_svc_error("strcpy error"); - } else { - media_svc_error("Can't extract title from filepath [%s]", content_info->path); - } - } - - return MS_MEDIA_ERR_NONE; - } else { - media_svc_debug("Some Not OMA Content's metadata is not incrypted so fileinfo can extracted metadata"); - } - } -#endif /*Get Content attribute ===========*/ mmf_error = mm_file_create_content_attrs(&content, content_info->path); @@ -1468,29 +1382,6 @@ int _media_svc_extract_media_metadata(sqlite3 *handle, media_svc_content_info_s } else { SAFE_FREE(err_attr_name); } -#if 0 - //if ((!thumb_extracted_from_drm) && (extract_thumbnail == TRUE)) - { - /* Extracting thumbnail */ - char thumb_path[MEDIA_SVC_PATHNAME_SIZE + 1] = {0, }; - int width = 0; - int height = 0; - - ret = thumbnail_request_from_db_with_size(content_info->path, thumb_path, sizeof(thumb_path), &width, &height); - if (ret < 0) { - media_svc_error("thumbnail_request_from_db failed: %d", ret); - } else { - //media_svc_debug("thumbnail_request_from_db success: %s", thumb_path); - } - - ret = __media_svc_malloc_and_strncpy(&content_info->thumbnail_path, thumb_path); - if(ret != MS_MEDIA_ERR_NONE) - media_svc_error("strcpy error"); - - if (content_info->media_meta.width <= 0) content_info->media_meta.width = width; - if (content_info->media_meta.height <= 0) content_info->media_meta.height = height; - } -#endif } mmf_error = mm_file_destroy_tag_attrs(tag); @@ -1624,55 +1515,6 @@ bool _media_svc_is_drm_file(const char *path) return FALSE; } -int _media_svc_get_mime_in_drm_info(const char *path, char *mime, drm_content_info_s **drm_contentInfo) -{ -#ifdef __SUPPORT_DRM - int ret = MS_MEDIA_ERR_NONE; - drm_file_type_e file_type = DRM_TYPE_UNDEFINED; - - if (path == NULL || mime == NULL) - return MS_MEDIA_ERR_INVALID_PARAMETER; - - ret = drm_get_file_type(path, &file_type); - if (ret != DRM_RETURN_SUCCESS) { - media_svc_error("drm_get_file_type() failed : %d", ret); - return MS_MEDIA_ERR_INTERNAL; - } else { - if (file_type == DRM_TYPE_OMA_V1 - || file_type == DRM_TYPE_OMA_V2 - || file_type == DRM_TYPE_OMA_PD) { - *drm_contentInfo = malloc(sizeof(drm_content_info_s)); - memset(*drm_contentInfo,0x0,sizeof(drm_content_info_s)); - ret = drm_get_content_info(path, *drm_contentInfo); - if (ret != DRM_RETURN_SUCCESS) { - media_svc_error("drm_svc_get_content_info() fails :%d ", ret); - free(*drm_contentInfo); - *drm_contentInfo = NULL; - return MS_MEDIA_ERR_INTERNAL; - } - - if (STRING_VALID((*drm_contentInfo)->mime_type)) { - strncpy(mime,(*drm_contentInfo)->mime_type, MEDIA_SVC_METADATA_LEN_MAX); - media_svc_debug("DRM contentType : %s",(*drm_contentInfo)->mime_type); - } else { - free(*drm_contentInfo); - *drm_contentInfo = NULL; - return MS_MEDIA_ERR_INTERNAL; - } - } else { - media_svc_error("THIS IS DRM BUT YOU SHOULD USE API OF AUL LIBRARY"); - *drm_contentInfo = NULL; - return MS_MEDIA_ERR_INTERNAL; - } - } - - return MS_MEDIA_ERR_NONE; -#else - *drm_contentInfo = NULL; - return MS_MEDIA_ERR_INTERNAL; -#endif -} - int _media_svc_get_content_type_from_mime(const char * path, const char * mimetype, int * category) { int i = 0; @@ -1748,31 +1590,11 @@ int _media_svc_get_content_type_from_mime(const char * path, const char * mimety return err; } -/* -drm_contentifo is not NULL, if the file is OMA DRM. -If the file is not OMA DRM, drm_contentinfo must be NULL. -*/ -int _media_svc_get_mime_type(const char *path, char *mimetype, drm_bool_type_e *is_drm, drm_content_info_s **drm_contentInfo) +int _media_svc_get_mime_type(const char *path, char *mimetype) { - int ret = MS_MEDIA_ERR_NONE; - if (path == NULL) return MS_MEDIA_ERR_INVALID_PARAMETER; -#ifdef __SUPPORT_DRM - /* In case of drm file. */ - if (_media_svc_is_drm_file(path)) { - *is_drm = DRM_TRUE; - ret = _media_svc_get_mime_in_drm_info(path, mimetype, drm_contentInfo); - if (ret == MS_MEDIA_ERR_NONE) { - return ret; - } - } -#else - *is_drm = DRM_FALSE; - *drm_contentInfo = NULL; -#endif - /*in case of normal files or failure to get mime in drm */ if (aul_get_mime_from_file(path, mimetype, 255) < 0) { media_svc_error("aul_get_mime_from_file fail"); diff --git a/src/common/media-svc.c b/src/common/media-svc.c index 4734a13..b20ab40 100755 --- a/src/common/media-svc.c +++ b/src/common/media-svc.c @@ -21,7 +21,6 @@ #include #include -#include #include #include "media-svc.h" #include "media-svc-media.h" @@ -145,12 +144,8 @@ int media_svc_get_storage_type(const char *path, media_svc_storage_type_e *stora int media_svc_get_mime_type(const char *path, char *mimetype) { int ret = MS_MEDIA_ERR_NONE; - drm_bool_type_e is_drm = DRM_FALSE; - drm_content_info_s *drm_contentInfo = NULL; - ret = _media_svc_get_mime_type(path, mimetype, &is_drm, &drm_contentInfo); - - SAFE_FREE(drm_contentInfo); + ret = _media_svc_get_mime_type(path, mimetype); return ret; } @@ -246,7 +241,6 @@ int media_svc_insert_item_bulk(MediaSvcHandle *handle, media_svc_storage_type_e sqlite3 * db_handle = (sqlite3 *)handle; char folder_uuid[MEDIA_SVC_UUID_SIZE+1] = {0,}; media_svc_media_type_e media_type; - drm_content_info_s *drm_contentInfo = NULL; media_svc_retvm_if(db_handle == NULL, MS_MEDIA_ERR_INVALID_PARAMETER, "Handle is NULL"); media_svc_retvm_if(!STRING_VALID(path), MS_MEDIA_ERR_INVALID_PARAMETER, "path is NULL"); @@ -260,8 +254,7 @@ int media_svc_insert_item_bulk(MediaSvcHandle *handle, media_svc_storage_type_e memset(&content_info, 0, sizeof(media_svc_content_info_s)); /*Set media info*/ - /* if drm_contentinfo is not NULL, the file is OMA DRM.*/ - ret = _media_svc_set_media_info(&content_info, storage_type, path, &media_type, FALSE, &drm_contentInfo); + ret = _media_svc_set_media_info(&content_info, storage_type, path, &media_type, FALSE); media_svc_retv_if(ret != MS_MEDIA_ERR_NONE, ret); if(media_type == MEDIA_SVC_MEDIA_TYPE_OTHER) { @@ -269,9 +262,8 @@ int media_svc_insert_item_bulk(MediaSvcHandle *handle, media_svc_storage_type_e } else if(media_type == MEDIA_SVC_MEDIA_TYPE_IMAGE) { ret = _media_svc_extract_image_metadata(&content_info, media_type); } else { - ret = _media_svc_extract_media_metadata(handle, &content_info, media_type, drm_contentInfo, uid); + ret = _media_svc_extract_media_metadata(handle, &content_info, media_type, uid); } - SAFE_FREE(drm_contentInfo); media_svc_retv_if(ret != MS_MEDIA_ERR_NONE, ret); /*Set or Get folder id*/ @@ -339,7 +331,6 @@ int media_svc_insert_item_immediately(MediaSvcHandle *handle, media_svc_storage_ sqlite3 * db_handle = (sqlite3 *)handle; char folder_uuid[MEDIA_SVC_UUID_SIZE+1] = {0,}; media_svc_media_type_e media_type; - drm_content_info_s *drm_contentInfo = NULL; media_svc_retvm_if(db_handle == NULL, MS_MEDIA_ERR_INVALID_PARAMETER, "Handle is NULL"); media_svc_retvm_if(!STRING_VALID(path), MS_MEDIA_ERR_INVALID_PARAMETER, "path is NULL"); @@ -353,7 +344,7 @@ int media_svc_insert_item_immediately(MediaSvcHandle *handle, media_svc_storage_ memset(&content_info, 0, sizeof(media_svc_content_info_s)); /*Set media info*/ - ret = _media_svc_set_media_info(&content_info, storage_type, path, &media_type, FALSE, &drm_contentInfo); + ret = _media_svc_set_media_info(&content_info, storage_type, path, &media_type, FALSE); media_svc_retv_if(ret != MS_MEDIA_ERR_NONE, ret); if(media_type == MEDIA_SVC_MEDIA_TYPE_OTHER) { @@ -362,7 +353,7 @@ int media_svc_insert_item_immediately(MediaSvcHandle *handle, media_svc_storage_ ret = _media_svc_extract_image_metadata(&content_info, media_type); media_svc_retv_if(ret != MS_MEDIA_ERR_NONE, ret); } else { - ret = _media_svc_extract_media_metadata(handle, &content_info, media_type, drm_contentInfo, uid); + ret = _media_svc_extract_media_metadata(handle, &content_info, media_type, uid); media_svc_retv_if(ret != MS_MEDIA_ERR_NONE, ret); } @@ -864,7 +855,6 @@ int media_svc_refresh_item(MediaSvcHandle *handle, media_svc_storage_type_e stor int ret = MS_MEDIA_ERR_NONE; sqlite3 * db_handle = (sqlite3 *)handle; media_svc_media_type_e media_type; - drm_content_info_s *drm_contentInfo = NULL; media_svc_retvm_if(db_handle == NULL, MS_MEDIA_ERR_INVALID_PARAMETER, "Handle is NULL"); media_svc_retvm_if(!STRING_VALID(path), MS_MEDIA_ERR_INVALID_PARAMETER, "path is NULL"); @@ -878,7 +868,7 @@ int media_svc_refresh_item(MediaSvcHandle *handle, media_svc_storage_type_e stor memset(&content_info, 0, sizeof(media_svc_content_info_s)); /*Set media info*/ - ret = _media_svc_set_media_info(&content_info, storage_type, path, &media_type, TRUE, &drm_contentInfo); + ret = _media_svc_set_media_info(&content_info, storage_type, path, &media_type, TRUE); media_svc_retv_if(ret != MS_MEDIA_ERR_NONE, ret); /* Initialize thumbnail information to remake thumbnail. */ @@ -912,7 +902,7 @@ int media_svc_refresh_item(MediaSvcHandle *handle, media_svc_storage_type_e stor return ret; } } else { - ret = _media_svc_extract_media_metadata(handle, &content_info, media_type, drm_contentInfo, uid); + ret = _media_svc_extract_media_metadata(handle, &content_info, media_type, uid); if (ret != MS_MEDIA_ERR_NONE) { _media_svc_destroy_noti_item(noti_item); return ret; diff --git a/src/include/common/media-svc-util.h b/src/include/common/media-svc-util.h index b0b4d46..9e2261c 100755 --- a/src/include/common/media-svc-util.h +++ b/src/include/common/media-svc-util.h @@ -27,7 +27,6 @@ #include #include #include -#include #include "media-svc-types.h" #include "media-svc-env.h" @@ -59,9 +58,9 @@ bool _media_svc_get_thumbnail_path(media_svc_storage_type_e storage_type, char * bool _media_svc_get_file_ext(const char *file_path, char *file_ext); int _media_svc_get_file_time(const char *full_path); int _media_svc_set_media_info(media_svc_content_info_s *content_info, media_svc_storage_type_e storage_type, - const char *path, media_svc_media_type_e *media_type, bool refresh, drm_content_info_s **drm_contentInfo); + const char *path, media_svc_media_type_e *media_type, bool refresh); int _media_svc_extract_image_metadata(media_svc_content_info_s *content_info, media_svc_media_type_e media_type); -int _media_svc_extract_media_metadata(sqlite3 *handle, media_svc_content_info_s *content_info, media_svc_media_type_e media_type, drm_content_info_s *drm_contentInfo, uid_t uid); +int _media_svc_extract_media_metadata(sqlite3 *handle, media_svc_content_info_s *content_info, media_svc_media_type_e media_type, uid_t uid); int __media_svc_malloc_and_strncpy(char **dst, const char *src); void _media_svc_destroy_content_info(media_svc_content_info_s *content_info); int _media_svc_get_store_type_by_path(const char *path, media_svc_storage_type_e *storage_type); @@ -139,12 +138,10 @@ static const char sound_mime_table[SOUND_MIME_NUM][MIME_LENGTH] = { }; bool _media_svc_is_drm_file(const char *path); -int _media_svc_get_mime_in_drm_info(const char *path, char *mime, drm_content_info_s **drm_contentInfo); int _media_svc_get_content_type_from_mime(const char * path, const char * mimetype, int * category); int _media_svc_get_pinyin_str(const char *src_str, char **pinyin_str); bool _media_svc_check_pinyin_support(void); -int _media_svc_get_mime_type(const char *path, char *mimetype, drm_bool_type_e *is_drm, drm_content_info_s **drm_contentInfo); - +int _media_svc_get_mime_type(const char *path, char *mimetype); int _media_svc_get_media_type(const char *path, const char *mime_type, media_svc_media_type_e *media_type); #ifdef __cplusplus