History

lavu/threadmessage: add av_thread_message_queue_nb_elems()

Clément Bœsch committed 8 years ago

Commit 71fa82b1 parent 02e49705 files · +28 −2Browse files

Showing the changes to tests/api/api-threadmessage-test.c (1 of 5 files). Show all

Unified · Split

tests/api/api-threadmessage-test.c+3−1
@@ -130,7 +130,9 @@ static void *receiver_thread(void *arg) · 129 unmodified lines
130130
131131 for (i = 0; i < rd->workload; i++) {
132132 if (rand() % rd->workload < rd->workload / 10) {
133− av_log(NULL, AV_LOG_INFO, "receiver #%d: flushing the queue\n", rd->id);
133+ av_log(NULL, AV_LOG_INFO, "receiver #%d: flushing the queue, "
134+ "discarding %d message(s)\n", rd->id,
135+ av_thread_message_queue_nb_elems(rd->queue));
134136 av_thread_message_flush(rd->queue);
135137 } else {
136138 struct message msg;

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