fdsink: remove unused struct member `bytes_written`
authorMathieu Duponchelle <mathieu@centricular.com>
Mon, 11 May 2020 22:57:36 +0000 (00:57 +0200)
committerGStreamer Merge Bot <gitlab-merge-bot@gstreamer-foundation.org>
Wed, 20 May 2020 14:10:14 +0000 (14:10 +0000)
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/476>

plugins/elements/gstfdsink.c
plugins/elements/gstfdsink.h

index f715ac1..122a6a6 100644 (file)
@@ -170,7 +170,6 @@ gst_fd_sink_init (GstFdSink * fdsink)
 {
   fdsink->fd = 1;
   fdsink->uri = g_strdup_printf ("fd://%d", fdsink->fd);
-  fdsink->bytes_written = 0;
   fdsink->current_pos = 0;
 
   gst_base_sink_set_sync (GST_BASE_SINK (fdsink), FALSE);
@@ -262,7 +261,6 @@ gst_fd_sink_render_list (GstBaseSink * bsink, GstBufferList * buffer_list)
     ret = gst_writev_buffer_list (GST_OBJECT_CAST (sink), sink->fd, sink->fdset,
         buffer_list, &bytes_written, skip, 0, -1, NULL);
 
-    sink->bytes_written += bytes_written;
     sink->current_pos += bytes_written;
     skip += bytes_written;
 
@@ -298,7 +296,6 @@ gst_fd_sink_render (GstBaseSink * bsink, GstBuffer * buffer)
     ret = gst_writev_buffer (GST_OBJECT_CAST (sink), sink->fd, sink->fdset,
         buffer, &bytes_written, skip, 0, -1, NULL);
 
-    sink->bytes_written += bytes_written;
     sink->current_pos += bytes_written;
     skip += bytes_written;
 
@@ -374,7 +371,6 @@ gst_fd_sink_start (GstBaseSink * basesink)
   gst_poll_add_fd (fdsink->fdset, &fd);
   gst_poll_fd_ctl_write (fdsink->fdset, &fd, TRUE);
 
-  fdsink->bytes_written = 0;
   fdsink->current_pos = 0;
 
   fdsink->seekable = gst_fd_sink_do_seek (fdsink, 0);
index c038ce0..e0ab006 100644 (file)
@@ -58,7 +58,6 @@ struct _GstFdSink {
   GstPoll *fdset;
 
   int fd;
-  guint64 bytes_written;
   guint64 current_pos;
 
   gboolean seekable;