diff options
author | wm4 <wm4@nowhere> | 2014-04-23 20:45:10 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2014-04-23 21:16:52 +0200 |
commit | 80ff94131b477ad9156f1c68da7b8588544fee33 (patch) | |
tree | a98ba8c3f4bcf96fc5ba0eb7c7de57a1ab87ab64 /stream | |
parent | 29b726039821ff3f0435644c791412ed8a75319a (diff) | |
download | mpv-80ff94131b477ad9156f1c68da7b8588544fee33.tar.bz2 mpv-80ff94131b477ad9156f1c68da7b8588544fee33.tar.xz |
dispatch: implement timeout
Note that this mechanism is similarly "unreliable" as for example
pthread_cond_timedwait(). Trying to target the exact wait time will just
make it more complex.
The main use case for this is for threads which either use the dispatch
centrally and want mp_dispatch_queue_process to do a blocking wait for
new work, or threads which have to implement timers. For the former,
anything is fine, as long as they don't have to do active waiting for
new works. For the former, callers are better off recalculating their
deadline after every call.
Diffstat (limited to 'stream')
0 files changed, 0 insertions, 0 deletions