g_time_add callback is registered twice 39/127839/1
authorGilbok Lee <gilbok.lee@samsung.com>
Tue, 2 May 2017 03:07:44 +0000 (12:07 +0900)
committerGilbok Lee <gilbok.lee@samsung.com>
Tue, 2 May 2017 03:07:44 +0000 (12:07 +0900)
modified typo error

[Version] 0.10.5
[Profile] Mobile, TV
[Issue Type] Fix bugs

Change-Id: I54bf98bffc6f24c9ec9c12b2b1bf0ebb728d3e26

packaging/libmm-transcode.spec
transcode/include/mm_transcode_internal.h
transcode/mm_transcode_pipeline.c
transcode/mm_transcode_seek.c

index 03f5d0e..7a42752 100644 (file)
@@ -1,6 +1,6 @@
 Name:       libmm-transcode
 Summary:    Multimedia Framework Video Transcode Library
-Version:    0.10.4
+Version:    0.10.5
 Release:    0
 Group:      System/Libraries
 License:    Apache-2.0
index e5b4ba1..a00fe33 100644 (file)
@@ -170,7 +170,7 @@ typedef struct _handle_property_s
        gchar *mux;
        gulong video_cb_probe_id;
        gulong audio_cb_probe_id;
-       guint progrss_event_id;
+       guint progress_event_id;
        const gchar *mime;
        gchar format[sizeof(GST_VIDEO_FORMATS_ALL)];
        gint in_width;
index a6ece61..269f935 100755 (executable)
@@ -117,10 +117,10 @@ int _mm_cleanup_signal(handle_s *handle)
                debug_log("g_source_remove (video_cb_probe_id)");
        }
 
-       if (handle->property->progrss_event_id) {
-               g_source_remove(handle->property->progrss_event_id);
-               handle->property->progrss_event_id = 0;
-               debug_log("g_source_remove (progrss_event_id)");
+       if (handle->property->progress_event_id) {
+               g_source_remove(handle->property->progress_event_id);
+               handle->property->progress_event_id = 0;
+               debug_log("g_source_remove (progress_event_id)");
        }
 
        if (handle->encodebin->audio_event_probe_id) {
index 26d1788..9ea3b94 100755 (executable)
@@ -1115,7 +1115,7 @@ int _mm_transcode_param_flush(handle_s *handle)
        handle->property->is_busy = FALSE;
        handle->property->audio_cb_probe_id = 0;
        handle->property->video_cb_probe_id = 0;
-       handle->property->progrss_event_id = 0;
+       handle->property->progress_event_id = 0;
        handle->property->seek_idx = 0;
 
        return ret;
@@ -1143,8 +1143,10 @@ static int _mm_transcode_play(handle_s *handle)
 
        debug_log("[SEEK: %d] width: %d height: %d start_pos: %d duration: %d (%d) seek_mode: %d outputfile: %s", handle->param->seeking, handle->param->resolution_width, handle->param->resolution_height, handle->param->start_pos, handle->param->duration, handle->property->end_pos, handle->param->seek_mode, handle->param->outputfile);
 
-       handle->property->progrss_event_id = g_timeout_add(LAZY_PAUSE_TIMEOUT_MSEC, (GSourceFunc) _mm_cb_print_position, handle);
-       debug_log("Timer (id=[%d], timeout=[%d ms])\n", handle->property->progrss_event_id, LAZY_PAUSE_TIMEOUT_MSEC);
+       if (!handle->property->progress_event_id) {
+               handle->property->progress_event_id = g_timeout_add(LAZY_PAUSE_TIMEOUT_MSEC, (GSourceFunc) _mm_cb_print_position, handle);
+               debug_log("Timer (id=[%d], timeout=[%d ms])\n", handle->property->progress_event_id, LAZY_PAUSE_TIMEOUT_MSEC);
+       }
 
        return ret;
 }