mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-09 17:05:52 +00:00
gst/gstdata.c: whoops, return values were wrong, so writable data was marked as non-writable and vice versa. (fixes #...
Original commit message from CVS: * gst/gstdata.c: (gst_data_is_writable): whoops, return values were wrong, so writable data was marked as non-writable and vice versa. (fixes #143953, spotted by Francis Labonte) Shows how rarely we need to copy data ;)
This commit is contained in:
parent
a0873781bf
commit
e242dece5b
2 changed files with 11 additions and 1 deletions
|
@ -1,3 +1,11 @@
|
||||||
|
2004-06-20 Benjamin Otte <otte@gnome.org>
|
||||||
|
|
||||||
|
* gst/gstdata.c: (gst_data_is_writable):
|
||||||
|
whoops, return values were wrong, so writable data was marked as
|
||||||
|
non-writable and vice versa. (fixes #143953, spotted by Francis
|
||||||
|
Labonte)
|
||||||
|
Shows how rarely we need to copy data ;)
|
||||||
|
|
||||||
2004-06-20 Benjamin Otte <otte@gnome.org>
|
2004-06-20 Benjamin Otte <otte@gnome.org>
|
||||||
|
|
||||||
* testsuite/schedulers/.cvsignore:
|
* testsuite/schedulers/.cvsignore:
|
||||||
|
|
|
@ -128,7 +128,9 @@ gst_data_is_writable (GstData * data)
|
||||||
|
|
||||||
refcount = gst_atomic_int_read (&data->refcount);
|
refcount = gst_atomic_int_read (&data->refcount);
|
||||||
|
|
||||||
if (refcount == 1 && !GST_DATA_FLAG_IS_SET (data, GST_DATA_READONLY))
|
if (refcount >= 1)
|
||||||
|
return FALSE;
|
||||||
|
if (GST_DATA_FLAG_IS_SET (data, GST_DATA_READONLY))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
|
Loading…
Reference in a new issue