diff options
author | Tim-Philipp Müller <tim@centricular.com> | 2014-09-10 19:27:27 +0100 |
---|---|---|
committer | Tim-Philipp Müller <tim@centricular.com> | 2014-09-10 19:27:27 +0100 |
commit | 8990a61221eb4f159af8676cbc78db5de1bbb031 (patch) | |
tree | ed4af558e1b8daf1712c1b70de36502071b31ca5 /gst/aiff | |
parent | c08c99b8949942c566112e814ceece4a0b1c1e8f (diff) |
aiffmux: allocate byte writer on stack
Diffstat (limited to 'gst/aiff')
-rw-r--r-- | gst/aiff/aiffmux.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/gst/aiff/aiffmux.c b/gst/aiff/aiffmux.c index 593888496..f2e0f6979 100644 --- a/gst/aiff/aiffmux.c +++ b/gst/aiff/aiffmux.c @@ -242,7 +242,7 @@ gst_aiff_mux_push_header (GstAiffMux * aiffmux, guint32 audio_data_size) { GstFlowReturn ret; GstBuffer *outbuf; - GstByteWriter *writer; + GstByteWriter writer; GstSegment seg; /* seek to beginning of file */ @@ -258,13 +258,13 @@ gst_aiff_mux_push_header (GstAiffMux * aiffmux, guint32 audio_data_size) GST_DEBUG_OBJECT (aiffmux, "writing header with datasize=%u", audio_data_size); - writer = gst_byte_writer_new_with_size (AIFF_HEADER_LEN, TRUE); + gst_byte_writer_init_with_size (&writer, AIFF_HEADER_LEN, TRUE); - gst_aiff_mux_write_form_header (aiffmux, audio_data_size, writer); - gst_aiff_mux_write_comm_header (aiffmux, audio_data_size, writer); - gst_aiff_mux_write_ssnd_header (aiffmux, audio_data_size, writer); + gst_aiff_mux_write_form_header (aiffmux, audio_data_size, &writer); + gst_aiff_mux_write_comm_header (aiffmux, audio_data_size, &writer); + gst_aiff_mux_write_ssnd_header (aiffmux, audio_data_size, &writer); - outbuf = gst_byte_writer_free_and_get_buffer (writer); + outbuf = gst_byte_writer_reset_and_get_buffer (&writer); ret = gst_pad_push (aiffmux->srcpad, outbuf); |