OSDN Git Service
(root)
/
android-x86
/
external-ffmpeg.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c4503a2
)
udp: add missing mutex unlock
author
Michael Niedermayer
<michaelni@gmx.at>
Sat, 20 Oct 2012 21:31:32 +0000
(23:31 +0200)
committer
Michael Niedermayer
<michaelni@gmx.at>
Sat, 20 Oct 2012 21:31:32 +0000
(23:31 +0200)
Fixes CID703688
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavformat/udp.c
patch
|
blob
|
history
diff --git
a/libavformat/udp.c
b/libavformat/udp.c
index
433f961
..
c6f0a1f
100644
(file)
--- a/
libavformat/udp.c
+++ b/
libavformat/udp.c
@@
-766,8
+766,10
@@
static int udp_read(URLContext *h, uint8_t *buf, int size)
int64_t t = av_gettime() + 100000;
struct timespec tv = { .tv_sec = t / 1000000,
.tv_nsec = (t % 1000000) * 1000 };
- if (pthread_cond_timedwait(&s->cond, &s->mutex, &tv) < 0)
+ if (pthread_cond_timedwait(&s->cond, &s->mutex, &tv) < 0) {
+ pthread_mutex_unlock(&s->mutex);
return AVERROR(errno == ETIMEDOUT ? EAGAIN : errno);
+ }
nonblock = 1;
}
} while( 1);