Attempt to load non-gzipped test disks (aborted from previous runs)

This commit is contained in:
Aaron Culliney 2014-04-28 11:55:51 -07:00
parent 615204ebc9
commit 304442655c
2 changed files with 14 additions and 4 deletions

View File

@ -43,8 +43,13 @@ static void sha1_to_str(const uint8_t * const md, char *buf) {
}
TEST test_boot_disk() {
char *disk = "./disks/testdisplay1.dsk.gz";
ASSERT(!c_new_diskette_6(0, disk, 0));
char *disk = strdup("./disks/testdisplay1.dsk.gz");
if (c_new_diskette_6(0, disk, 0)) {
int len = strlen(disk);
disk[len-3] = '\0';
ASSERT(!c_new_diskette_6(0, disk, 0));
}
free(disk);
BOOT_TO_DOS();

View File

@ -49,8 +49,13 @@ static void sha1_to_str(const uint8_t * const md, char *buf) {
// VM TESTS ...
TEST test_boot_disk() {
char *disk = "./disks/testvm1.dsk.gz";
ASSERT(!c_new_diskette_6(0, disk, 0));
char *disk = strdup("./disks/testvm1.dsk.gz");
if (c_new_diskette_6(0, disk, 0)) {
int len = strlen(disk);
disk[len-3] = '\0';
ASSERT(!c_new_diskette_6(0, disk, 0));
}
free(disk);
BOOT_TO_DOS();