diff options
author | Vito Caputo <vcaputo@pengaru.com> | 2023-06-15 19:09:50 -0700 |
---|---|---|
committer | Vito Caputo <vcaputo@pengaru.com> | 2023-06-15 19:09:50 -0700 |
commit | 3da9ffaefe9c5557cd8eb8c61e34471b19ca0c5f (patch) | |
tree | f21fd53e83889d2fe046fad1a4a7a19627666eeb /src | |
parent | 74a734206e04ec674b0af0179d64a2e8bcc161d9 (diff) |
main: quit when the stream ends
I can't see this staying so simple for very long, but for now
this at least enables making rototiller-based rkt-sequenced demos
that exit gracefully when they're finished.
In a future where rtv may play embedded rkt configs+tracks, it
needs a way to detect the end of stream without making main exit.
But I'll cross that bridge when I get there...
Diffstat (limited to 'src')
-rw-r--r-- | src/main.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -411,7 +411,7 @@ int main(int argc, const char *argv[]) pexit_if(pthread_create(&rototiller.thread, NULL, rototiller_thread, &rototiller) != 0, "unable to create dispatch thread"); - for (;;) { + while (til_stream_active(rototiller.stream)) { if (til_fb_flip(rototiller.fb) < 0) break; |