| OLD | NEW |
| 1 /* Copyright 1994-1995, 1999, 2002-2004, 2007-2012 Free Software | 1 /* Copyright 1994-1995, 1999, 2002-2004, 2007-2012 Free Software |
| 2 Foundation, Inc. | 2 Foundation, Inc. |
| 3 | 3 |
| 4 This program is free software; you can redistribute it and/or modify | 4 This program is free software; you can redistribute it and/or modify |
| 5 it under the terms of the GNU General Public License as published by | 5 it under the terms of the GNU General Public License as published by |
| 6 the Free Software Foundation; either version 3 of the License, or | 6 the Free Software Foundation; either version 3 of the License, or |
| 7 (at your option) any later version. | 7 (at your option) any later version. |
| 8 | 8 |
| 9 This program is distributed in the hope that it will be useful, | 9 This program is distributed in the hope that it will be useful, |
| 10 but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 but WITHOUT ANY WARRANTY; without even the implied warranty of |
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 77 | 77 |
| 78 int | 78 int |
| 79 main (int argc, char **argv, char **envp) | 79 main (int argc, char **argv, char **envp) |
| 80 #else | 80 #else |
| 81 int | 81 int |
| 82 main (argc, argv, envp) | 82 main (argc, argv, envp) |
| 83 int argc; | 83 int argc; |
| 84 char *argv[], **envp; | 84 char *argv[], **envp; |
| 85 #endif | 85 #endif |
| 86 { | 86 { |
| 87 #ifdef usestubs | |
| 88 set_debug_traps(); /* set breakpoint 5 here */ | |
| 89 breakpoint(); | |
| 90 #endif | |
| 91 if (argc == 12345) { /* an unlikely value < 2^16, in case uninited */ /* se
t breakpoint 6 here */ | 87 if (argc == 12345) { /* an unlikely value < 2^16, in case uninited */ /* se
t breakpoint 6 here */ |
| 92 fprintf (stderr, "usage: factorial <number>\n"); | 88 fprintf (stderr, "usage: factorial <number>\n"); |
| 93 return 1; | 89 return 1; |
| 94 } | 90 } |
| 95 printf ("%d\n", factorial (atoi ("6"))); /* set breakpoint 1 here */ | 91 printf ("%d\n", factorial (atoi ("6"))); /* set breakpoint 1 here */ |
| 96 /* set breakpoint 12 here */ | 92 /* set breakpoint 12 here */ |
| 97 marker1 (); /* set breakpoint 11 here */ | 93 marker1 (); /* set breakpoint 11 here */ |
| 98 marker2 (43); | 94 marker2 (43); |
| 99 marker3 ("stack", "trace"); | 95 marker3 ("stack", "trace"); |
| 100 marker4 (177601976L); | 96 marker4 (177601976L); |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 138 #endif | 134 #endif |
| 139 { | 135 { |
| 140 while (a /* set breakpoint 4 here */ | 136 while (a /* set breakpoint 4 here */ |
| 141 && b | 137 && b |
| 142 && c) | 138 && c) |
| 143 { | 139 { |
| 144 a--, b--, c--; | 140 a--, b--, c--; |
| 145 } | 141 } |
| 146 return 0; | 142 return 0; |
| 147 } | 143 } |
| OLD | NEW |