examples: use do/while loop for multi examples
authorDave Reisner <dreisner@archlinux.org>
Mon, 23 Jul 2012 15:34:25 +0000 (15:34 +0000)
committerDaniel Stenberg <daniel@haxx.se>
Mon, 27 Aug 2012 13:10:13 +0000 (15:10 +0200)
commit4c070de4fb01b4fbf29f8c463ba96da97b36bd2f
tree3be5aa0d1ff12fa758b8d0ddd88ba35095b4f668
parent54faab69cbdabe51bab1bdee0a9c69e423178084
examples: use do/while loop for multi examples

It's conceivable that after the first time curl_multi_perform returns,
the outvalue still_running will be 0, but work will have been done. This
is shown by a workload of small, purely file:// based URLs. Ensure that
we always read pending messages off the multi handle by forcing the
while loop to run at least once.
docs/examples/multi-app.c
docs/examples/multi-debugcallback.c
docs/examples/multi-double.c
docs/examples/multi-post.c
docs/examples/multi-single.c