Fix missing unlock 34/244134/2 accepted/tizen_6.0_unified accepted/tizen_6.0_unified_hotfix tizen_6.0 tizen_6.0_hotfix accepted/tizen/6.0/unified/20201030.114531 accepted/tizen/6.0/unified/hotfix/20201103.002837 accepted/tizen/unified/20200917.055804 submit/tizen/20200916.012329 submit/tizen/20200917.004955 submit/tizen_6.0/20201029.205104 submit/tizen_6.0_hotfix/20201102.192504 submit/tizen_6.0_hotfix/20201103.114804 tizen_6.0.m2_release
authorMinje Ahn <minje.ahn@samsung.com>
Tue, 15 Sep 2020 07:53:25 +0000 (16:53 +0900)
committerMinje Ahn <minje.ahn@samsung.com>
Tue, 15 Sep 2020 07:57:58 +0000 (16:57 +0900)
Change-Id: I5d7ee8ddee77bf239f472caa72d53fa6a18466c4
Signed-off-by: Minje Ahn <minje.ahn@samsung.com>
packaging/media-server.spec
src/server/media-server-scanner.c

index 6f177dd..5fe8c14 100755 (executable)
@@ -1,6 +1,6 @@
 Name:       media-server
 Summary:    A server for media content management
-Version:    0.4.17
+Version:    0.4.18
 Release:    0
 Group:      Multimedia/Service
 License:    Apache-2.0
index 831d306..8a97fd5 100755 (executable)
@@ -203,12 +203,14 @@ int ms_scanner_start(void)
                err = mkfifo(MS_SCANNER_FIFO_PATH_RES, MS_SCANNER_FIFO_MODE);
                if (err != 0) {
                        MS_DBG_STRERROR("mkfifo failed");
+                       g_mutex_unlock(&scanner_mutex);
                        return MS_MEDIA_ERR_INTERNAL;
                }
 
                fd = open(MS_SCANNER_FIFO_PATH_RES, O_RDWR);
                if (fd < 0) {
                        MS_DBG_STRERROR("fifo open failed");
+                       g_mutex_unlock(&scanner_mutex);
                        return MS_MEDIA_ERR_INTERNAL;
                }
 
@@ -217,6 +219,7 @@ int ms_scanner_start(void)
                if (err < 0) {
                        MS_DBG_STRERROR("fifo read failed");
                        close(fd);
+                       g_mutex_unlock(&scanner_mutex);
                        return MS_MEDIA_ERR_INTERNAL;
                }