Fix build warning 01/129601/1
authorHaejeong Kim <backto.kim@samsung.com>
Wed, 17 May 2017 06:44:50 +0000 (15:44 +0900)
committerHaejeong Kim <backto.kim@samsung.com>
Wed, 17 May 2017 06:44:50 +0000 (15:44 +0900)
Change-Id: I0102c19e611a29bacc70e364d88bc99f6cb61d7b

lib/media-util-ipc.c
src/server/media-server-device-block.c

index 6d12d31..6653cde 100755 (executable)
@@ -47,30 +47,9 @@ char MEDIA_IPC_PATH[][70] = {
        {"media-server/media_ipc_dcmdaemon.socket"},
 };
 
-static int _mkdir(const char *dir, mode_t mode)
-{
-       char tmp[256];
-       char *p = NULL;
-       size_t len;
-
-       snprintf(tmp, sizeof(tmp), "%s", dir);
-       len = strlen(tmp);
-       if (tmp[len - 1] == '/')
-               tmp[len - 1] = 0;
-       for (p = tmp + 1; *p; p++)
-               if (*p == '/') {
-                       *p = 0;
-                       mkdir(tmp, mode);
-                       *p = '/';
-               }
-
-       return mkdir(tmp, mode);
-}
-
 int ms_ipc_create_client_socket(int timeout_sec, ms_sock_info_s* sock_info)
 {
        int sock = -1;
-       struct sockaddr_un serv_addr;
        struct timeval tv_timeout = { timeout_sec, 0 };
 
        /*Create TCP Socket*/
index 366e46a..4a10baa 100755 (executable)
@@ -253,7 +253,7 @@ int ms_mmc_insert_handler(const char *mount_path)
        ms_dir_scan_type_t scan_type = MS_SCAN_ALL;
        char *storage_name = NULL;
        char *storage_path = NULL;
-       int validity = NULL;
+       int validity = 0;
        bool info_exist = FALSE;
        char *cid = NULL;
        uid_t uid = MEDIA_DEFAULT_UID;