Added stroserror-test.c
git-svn-id: svn://svn.cc65.org/cc65/trunk@1366 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
parent
fcd582e3cb
commit
c1c24d6df5
1 changed files with 31 additions and 0 deletions
31
testcode/lib/stroserror-test.c
Normal file
31
testcode/lib/stroserror-test.c
Normal file
|
@ -0,0 +1,31 @@
|
|||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include <conio.h>
|
||||
|
||||
|
||||
int main (void)
|
||||
{
|
||||
unsigned char error = 0;
|
||||
unsigned char line = 0;
|
||||
unsigned char maxx, maxy;
|
||||
screensize (&maxx, &maxy);
|
||||
do {
|
||||
printf ("%2d: %s\n", error, _stroserror (error));
|
||||
if (line == maxy-3) {
|
||||
printf ("Press any key...\n");
|
||||
if (cgetc () == 'q') {
|
||||
return 0;
|
||||
}
|
||||
clrscr ();
|
||||
line = 0;
|
||||
} else {
|
||||
++line;
|
||||
}
|
||||
++error;
|
||||
} while (error != 0);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Add table
Reference in a new issue