Sync usage with man page.
[netbsd-mini2440.git] / gnu / dist / gdb6 / gdb / testsuite / gdb.base / annota1.c
blob6a13ee9d53d4a6ffdc2c14bcb7fda99e7478cdff
1 #include <stdio.h>
2 #include <signal.h>
4 #ifdef __sh__
5 #define signal(a,b) /* Signals not supported on this target - make them go away */
6 #endif
9 #ifdef PROTOTYPES
10 void
11 handle_USR1 (int sig)
14 #else
15 void
16 handle_USR1 (sig)
17 int sig;
20 #endif
22 int value;
24 #ifdef PROTOTYPES
25 int
26 main (void)
27 #else
28 int
29 main ()
30 #endif
32 int my_array[3] = { 1, 2, 3 };
34 value = 7;
36 #ifdef SIGUSR1
37 signal (SIGUSR1, handle_USR1);
38 #endif
40 printf ("value is %d\n", value);
41 printf ("my_array[2] is %d\n", my_array[2]);
44 int i;
45 for (i = 0; i < 5; i++)
46 value++;
49 return 0;