Revision 21005,
513 bytes
checked in by ghudson, 20 years ago
(diff) |
This commit was generated by cvs2svn to compensate for changes in r21004,
which included commits to RCS files with non-trunk default branches.
|
Line | |
---|
1 | #include <gst/gst.h> |
---|
2 | |
---|
3 | /* test to make sure that we can do gst_main and gst_main_quit in succession */ |
---|
4 | /* FIXME: use mutexes */ |
---|
5 | |
---|
6 | gboolean mainloop = FALSE; |
---|
7 | |
---|
8 | static gboolean |
---|
9 | quit_main (gpointer data) |
---|
10 | { |
---|
11 | if (mainloop) { |
---|
12 | mainloop = FALSE; |
---|
13 | g_print ("-"); |
---|
14 | gst_main_quit (); |
---|
15 | } |
---|
16 | return TRUE; |
---|
17 | } |
---|
18 | |
---|
19 | int |
---|
20 | main (int argc, gchar * argv[]) |
---|
21 | { |
---|
22 | int i; |
---|
23 | |
---|
24 | g_timeout_add (1, quit_main, NULL); |
---|
25 | for (i = 0; i < 1000; ++i) { |
---|
26 | mainloop = TRUE; |
---|
27 | g_print ("+"); |
---|
28 | gst_main (); |
---|
29 | } |
---|
30 | g_print ("\n"); |
---|
31 | return 0; |
---|
32 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.