
This commit adds a GDB test case which tests GDB's BFD error handler hook for suppressing output of all but the first identical messages. See the comment at the beginning of bfd-errors.exp for details about this new test. I've tested this test for both 32- and 64-bit ELF files and also on both little endian and big endian machines. It also works for both native and remote targets. The only major restriction is that it only works for ELF targets.
44 lines
935 B
C
44 lines
935 B
C
/* Copyright 2022 Free Software Foundation, Inc.
|
|
This program is free software; you can redistribute it and/or modify
|
|
it under the terms of the GNU General Public License as published by
|
|
the Free Software Foundation; either version 3 of the License, or
|
|
(at your option) any later version.
|
|
|
|
This program is distributed in the hope that it will be useful,
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
GNU General Public License for more details.
|
|
|
|
You should have received a copy of the GNU General Public License
|
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
*/
|
|
|
|
#include <stdio.h>
|
|
|
|
void
|
|
foo1 ()
|
|
{
|
|
printf ("foo1 in lib\n");
|
|
return;
|
|
}
|
|
|
|
void
|
|
foo2()
|
|
{
|
|
printf ("foo2 in lib\n");
|
|
return;
|
|
}
|
|
|
|
void
|
|
foo3()
|
|
{
|
|
printf ("foo3 in lib\n");
|
|
return;
|
|
}
|
|
|
|
void
|
|
foo4()
|
|
{
|
|
printf ("foo4 in lib\n");
|
|
return;
|
|
}
|