Lukasz Marek
bba7b6fc41
Revert "lavu/buffer: add release function"
...
This reverts commit 3144440004
.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Lukasz Marek
3144440004
lavu/buffer: add release function
...
new function allows to unref buffer and obtain its data.
Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Stefano Sabatini
84be806982
lavu: define FF_MEMORY_POISON and use it
...
Allow single-place definition of constant used to fill poisoned memory.
12 years ago
Michael Niedermayer
dc92464aee
avutil: add av_buffer_get_ref_count()
...
This function is quite usefull for debuging
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Xidorn Quan
c81d2fa96d
avutil/buffer: add get_opaque
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
8e944891ce
avutil/buffer: remove redundant memory poisoning
...
Found-by: ubitux
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
058c002932
avutil/buffer: support memory poisoning
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
f1c3d8b344
avutil/add_to_pool: remove unused assgnment
...
Fixed CID991859
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
cea3a63ba3
avutil/buffer: Fix race in pool.
...
This race will always happen sooner or later in a multi-threaded
environment and it will over time lead to OOM.
This fix works by spinning, there are other ways by which this
can be fixed, like simply detecting the issue after it happened
and freeing the over-allocated memory or simply using a mutex.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
c603f22683
avutil/get_pool: remove dead operations whichs result is never used.
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
e3be7b1159
avutil/get_pool: Remove redundant initial atomic operation
...
602->442 dezicycles
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Clément Bœsch
80661e0f55
buffer: use the atomic get instead of the add and fetch variant.
12 years ago
Anton Khirnov
1cec0624d0
AVBuffer: add a new API for buffer pools
12 years ago
Anton Khirnov
8e401dbe90
lavu: add a new API for reference-counted data buffers.
12 years ago