mirror of
https://github.com/mauiaaron/apple2.git
synced 2024-12-24 18:31:51 +00:00
read_rand() is really just floating_bus() return
This commit is contained in:
parent
1ba28db8d7
commit
dcafae8390
@ -274,14 +274,6 @@ void c_initialize_tables() {
|
||||
/* RDVBLBAR switch */
|
||||
cpu65_vmem_r[0xC019] = iie_check_vbl;
|
||||
|
||||
/* random number generator */
|
||||
for (i = 0xC020; i < 0xC030; i++)
|
||||
{
|
||||
cpu65_vmem_r[i] =
|
||||
cpu65_vmem_w[i] =
|
||||
read_rand;
|
||||
}
|
||||
|
||||
/* TEXT switch */
|
||||
cpu65_vmem_r[0xC050] =
|
||||
cpu65_vmem_w[0xC050] =
|
||||
|
@ -103,7 +103,6 @@ void c_set_primary_char();
|
||||
void c_set_altchar();
|
||||
void c_initialize_font();
|
||||
void c_initialize_vm();
|
||||
uint8_t c_read_rand(uint16_t ea);
|
||||
void reinitialize();
|
||||
|
||||
/* vm hooks */
|
||||
|
@ -337,6 +337,8 @@ TEST test_cputrace_hello_nib() {
|
||||
PASS();
|
||||
}
|
||||
|
||||
#define EXPECTED_CPUTRACE_HELLO_PO_FILE_SIZE EXPECTED_CPUTRACE_HELLO_FILE_SIZE
|
||||
#define EXPECTED_CPUTRACE_HELLO_PO_SHA EXPECTED_CPUTRACE_HELLO_SHA
|
||||
TEST test_cputrace_hello_po() {
|
||||
test_setup_boot_disk(BLANK_PO, 0);
|
||||
|
||||
@ -365,18 +367,18 @@ TEST test_cputrace_hello_po() {
|
||||
FILE *fp = fopen(output, "r");
|
||||
fseek(fp, 0, SEEK_END);
|
||||
long expectedSize = ftell(fp);
|
||||
ASSERT(expectedSize == EXPECTED_CPUTRACE_HELLO_FILE_SIZE);
|
||||
ASSERT(expectedSize == EXPECTED_CPUTRACE_HELLO_PO_FILE_SIZE);
|
||||
fseek(fp, 0, SEEK_SET);
|
||||
unsigned char *buf = malloc(EXPECTED_CPUTRACE_HELLO_FILE_SIZE);
|
||||
if (fread(buf, 1, EXPECTED_CPUTRACE_HELLO_FILE_SIZE, fp) != EXPECTED_CPUTRACE_HELLO_FILE_SIZE) {
|
||||
unsigned char *buf = malloc(EXPECTED_CPUTRACE_HELLO_PO_FILE_SIZE);
|
||||
if (fread(buf, 1, EXPECTED_CPUTRACE_HELLO_PO_FILE_SIZE, fp) != EXPECTED_CPUTRACE_HELLO_PO_FILE_SIZE) {
|
||||
ASSERT(false);
|
||||
}
|
||||
fclose(fp); fp = NULL;
|
||||
SHA1(buf, EXPECTED_CPUTRACE_HELLO_FILE_SIZE, md);
|
||||
SHA1(buf, EXPECTED_CPUTRACE_HELLO_PO_FILE_SIZE, md);
|
||||
FREE(buf);
|
||||
|
||||
sha1_to_str(md, mdstr0);
|
||||
ASSERT(strcmp(mdstr0, EXPECTED_CPUTRACE_HELLO_SHA) == 0);
|
||||
ASSERT(strcmp(mdstr0, EXPECTED_CPUTRACE_HELLO_PO_SHA) == 0);
|
||||
} while(0);
|
||||
|
||||
unlink(output);
|
||||
@ -1050,9 +1052,6 @@ void test_disk(int argc, char **argv) {
|
||||
test_argc = argc;
|
||||
test_argv = argv;
|
||||
|
||||
c_read_rand(0x0);
|
||||
srandom(0); // force a known sequence
|
||||
|
||||
pthread_mutex_lock(&interface_mutex);
|
||||
|
||||
test_common_init(/*cputhread*/true);
|
||||
|
@ -3471,9 +3471,6 @@ void test_vm(int argc, char **argv) {
|
||||
test_argc = argc;
|
||||
test_argv = argv;
|
||||
|
||||
c_read_rand(0x0);
|
||||
srandom(0); // force a known sequence
|
||||
|
||||
pthread_mutex_lock(&interface_mutex);
|
||||
|
||||
test_common_init(/*cputhread*/true);
|
||||
|
Loading…
Reference in New Issue
Block a user