History

udp: support non blocking reads with fifo

Michael Niedermayer committed 14 years ago

Commit 9f50daf1 parent bc900501 file · +3 −0Browse files

Unified · Split

libavformat/udp.c+3−0
@@ -572,6 +572,9 @@ static int udp_read(URLContext *h, uint8_t *buf, int size) · 571 unmodified lines
572 } else if(s->circular_buffer_error){572 } else if(s->circular_buffer_error){
573 pthread_mutex_unlock(&s->mutex);573 pthread_mutex_unlock(&s->mutex);
574 return s->circular_buffer_error;574 return s->circular_buffer_error;
575 } else if(h->flags & AVIO_FLAG_NONBLOCK) {
576 pthread_mutex_unlock(&s->mutex);
577 return AVERROR(EAGAIN);
575 }578 }
576 else {579 else {
577 pthread_cond_wait(&s->cond, &s->mutex);580 pthread_cond_wait(&s->cond, &s->mutex);

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t