projects
/
platform
/
upstream
/
libav.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
bc1ef85
)
pthread: free progress if buffer allocation failed.
author
Ronald S. Bultje
<rsbultje@gmail.com>
Sat, 24 Mar 2012 19:19:19 +0000
(20:19 +0100)
committer
Anton Khirnov
<anton@khirnov.net>
Sat, 24 Mar 2012 20:29:35 +0000
(21:29 +0100)
Else we run out of progress variables after a few failed buffer
allocations.
Signed-off-by: Anton Khirnov <anton@khirnov.net>
libavcodec/pthread.c
patch
|
blob
|
history
diff --git
a/libavcodec/pthread.c
b/libavcodec/pthread.c
index
bbbc482
..
2a11195
100644
(file)
--- a/
libavcodec/pthread.c
+++ b/
libavcodec/pthread.c
@@
-951,6
+951,10
@@
int ff_thread_get_buffer(AVCodecContext *avctx, AVFrame *f)
ff_thread_finish_setup(avctx);
}
+ if (err) {
+ free_progress(f);
+ f->thread_opaque = NULL;
+ }
pthread_mutex_unlock(&p->parent->buffer_mutex);
return err;