Commit bb4999f6 authored by Uri Lublin's avatar Uri Lublin
Browse files

sink_event_probe: do not keep duration in a variable



If not ENABLE_RECORDER, then duration is assigned a value
but is never used - as the compiler optimizes it out.

Fixes the following clang warning:
  src/channel-display-gst.c:443:21: warning: Value stored to
  'duration' during its initialization is never read
Signed-off-by: Uri Lublin's avatarUri Lublin <uril@redhat.com>
parent 032ca202
......@@ -439,7 +439,6 @@ sink_event_probe(GstPad *pad, GstPadProbeInfo *info, gpointer data)
if (l) {
SpiceGstFrame *gstframe = l->data;
const SpiceFrame *frame = gstframe->encoded_frame;
int64_t duration = g_get_monotonic_time() - frame->creation_time;
/* Note that queue_len (the length of the queue prior to adding
* this frame) is crucial to correctly interpret the decoding time:
* - Less than MAX_DECODED_FRAMES means nothing blocked the
......@@ -450,7 +449,8 @@ sink_event_probe(GstPad *pad, GstPadProbeInfo *info, gpointer data)
record(frames_stats,
"frame mm_time %u size %u creation time %" PRId64
" decoded time %" PRId64 " queue %u before %u",
frame->mm_time, frame->size, frame->creation_time, duration,
frame->mm_time, frame->size, frame->creation_time,
g_get_monotonic_time() - frame->creation_time,
decoder->decoding_queue->length, gstframe->queue_len);
if (!decoder->appsink) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment