tests: don't set caps on unwritable buffers

Take the ref after setting the caps on a buffer because else the buffer is
techinically not writable.
This commit is contained in:
Wim Taymans 2009-08-05 13:48:40 +02:00
parent 49f24e2044
commit 96e342b686

View file

@ -580,8 +580,8 @@ GST_START_TEST (test_push_negotiation)
/* Should fail if src pad caps are incompatible with sink pad caps */
gst_pad_set_caps (src, caps);
gst_buffer_ref (buffer);
gst_buffer_set_caps (buffer, caps);
gst_buffer_ref (buffer);
fail_unless (gst_pad_push (src, buffer) == GST_FLOW_NOT_NEGOTIATED);
ASSERT_MINI_OBJECT_REFCOUNT (buffer, "buffer", 1);
gst_buffer_unref (buffer);