Eliminate some sleep usage.

* gdb.mi/basics.c (do_nothing): New.
        (main): Use do_nothing instead of printf, so that
        not to introduce race condition between output of
        inferiour and output of gdb. Do not use sleep as it
        is not generally available on embedded targets.
This commit is contained in:
Vladimir Prus 2009-04-03 11:23:19 +00:00
parent 6c03179c32
commit 7309f75664
2 changed files with 15 additions and 2 deletions

View File

@ -1,3 +1,13 @@
2009-04-03 Vladimir Prus <vladimir@codesourcery.com>
Eliminate some sleep usage.
* gdb.mi/basics.c (do_nothing): New.
(main): Use do_nothing instead of printf, so that
not to introduce race condition between output of
inferiour and output of gdb. Do not use sleep as it
is not generally available on embedded targets.
2009-04-02 Pedro Alves <pedro@codesourcery.com>
* gdb.server/ext-attach.exp: Expect an optional process id after

View File

@ -57,13 +57,16 @@ int return_1 ()
return 1;
}
void do_nothing (void)
{
}
main ()
{
callee1 (2, "A string argument.", 3.5);
callee1 (2, "A string argument.", 3.5);
sleep (1);
printf ("Hello, World!");
do_nothing (); /* Hello, World! */
callme (1);
callme (2);