Add Log for error case. 60/190360/2 submit/tizen/20190117.014905
authorSeokHoon Lee <andy.shlee@samsung.com>
Mon, 1 Oct 2018 07:47:31 +0000 (16:47 +0900)
committerSeokHoon Lee <andy.shlee@samsung.com>
Mon, 1 Oct 2018 07:55:01 +0000 (16:55 +0900)
- Add errro log in case of g_remove error
- Add return in test excutable file.
- Delete unused FFLAGS

Signed-off-by: SeokHoon Lee <andy.shlee@samsung.com>
Change-Id: Icd45b6dbc2c4a49acbca8181b262c227ac37feaf

packaging/capi-media-screen-mirroring.spec
src/scmirroring_src_ini.c
test_sink/scmirroring_sink_test.c
test_sink/scmirroring_sink_test_SBS.c

index 4f8bd9e9073177e8b4aa23cf698849bd48205eb2..cfce69c93571fc40bc7b3af15ed26098efa145b6 100644 (file)
@@ -1,6 +1,6 @@
 Name:       capi-media-screen-mirroring
 Summary:    A screen mirroring library in Tizen C API
-Version:    0.1.92
+Version:    0.1.93
 Release:    0
 Group:      Multimedia/API
 License:    Apache-2.0
@@ -49,7 +49,6 @@ export CFLAGS+=" -DSYSCONFDIR=\\\"%{_sysconfdir}\\\""
 %if 0%{?gcov:1}
 export CFLAGS+=" -fprofile-arcs -ftest-coverage"
 export CXXFLAGS+=" -fprofile-arcs -ftest-coverage"
-export FFLAGS+=" -fprofile-arcs -ftest-coverage"
 export LDFLAGS+=" -lgcov"
 %endif
 
index 38ca1ecb94a1b4c4213c39b852873fbbe8ad8a8e..3cdf995a0271a4b0f6bd13ebc7e30f100087d363 100644 (file)
@@ -255,7 +255,8 @@ void __scmirroring_ini_check_ini_status(void)
        } else {
                if (ini_buff.st_size < 5) {
                        scmirroring_debug("scmirroring.ini file size=%d, Corrupted! So, Removed\n", (int)ini_buff.st_size);
-                       g_remove(SCMIRRORING_SRC_INI_DEFAULT_PATH);
+                       if (g_remove(SCMIRRORING_SRC_INI_DEFAULT_PATH) == -1)
+                               scmirroring_error("failed to delete corrupted ini");
                }
        }
 }
index 80158e3044672cc2041482556dde0e416280090f..3403a71ec4263dfae5500f84c11b15a993c573bb 100644 (file)
@@ -1178,6 +1178,7 @@ gboolean _scmirroring_start_jobs(gpointer data)
 
 int main(int argc, char *argv[])
 {
+       int ret = 0;
        GIOChannel *stdin_channel;
 
        stdin_channel = g_io_channel_unix_new(0);
@@ -1187,7 +1188,7 @@ int main(int argc, char *argv[])
        __displaymenu();
 
        ops.data = NULL;
-       appcore_efl_main(PACKAGE, &argc, &argv, &ops);
+       ret = appcore_efl_main(PACKAGE, &argc, &argv, &ops);
 
-       return 0;
+       return ret;
 }
index cf8da4bda1cdb68c44e4b2b4bb24b036096b9559..2e236a9d5ca5fa9f0ab3500e2d2a19561e9672f0 100644 (file)
@@ -1251,6 +1251,7 @@ gboolean _scmirroring_start_jobs(gpointer data)
 
 int main(int argc, char *argv[])
 {
+       int ret = 0;
        GIOChannel *stdin_channel;
 
        stdin_channel = g_io_channel_unix_new(0);
@@ -1260,7 +1261,7 @@ int main(int argc, char *argv[])
        __displaymenu();
 
        ops.data = NULL;
-       appcore_efl_main(PACKAGE, &argc, &argv, &ops);
+       ret = appcore_efl_main(PACKAGE, &argc, &argv, &ops);
 
-       return 0;
+       return ret;
 }