Previous 15994 Revisions Next

r8094 Thursday 20th May, 2010 at 01:06:06 UTC by Firewave
Handle loadflags necessary for aes
[src/mess]softlist.c

src/mess/softlist.c
r8093r8094
560560                        char *hashdata = (char *)pool_malloc_lib( swlist->pool, sizeof(char) * ( strlen(str_crc) + strlen(str_sha1) + 7 + 4 ) );
561561                        int baddump = ( str_status && !strcmp(str_status,"baddump") ) ? 1 : 0;
562562                        int nodump = ( str_status && !strcmp(str_status,"nodump" ) ) ? 1 : 0;
563                        int romflags = 0;
563564
564565                        if ( !s_name || !hashdata )
565566                           return;
r8093r8094
567568                        strcpy( s_name, str_name );
568569                        sprintf( hashdata, "c:%s#s:%s#%s", str_crc, str_sha1, ( nodump ? NO_DUMP : ( baddump ? BAD_DUMP : "" ) ) );
569570
571                        /* Handle loadflag attribute */
572                        if ( str_loadflag && !strcmp(str_loadflag,"load16_word_swap") )
573                           romflags = ROM_GROUPWORD | ROM_REVERSE;
574                        else if ( str_loadflag && !strcmp(str_loadflag,"load16_byte") )
575                           romflags = ROM_SKIP(1);
576
570577                        /* ROM_LOAD( name, offset, length, hash ) */
571                        add_rom_entry( swlist, s_name, hashdata, offset, length, ROMENTRYTYPE_ROM );
578                        add_rom_entry( swlist, s_name, hashdata, offset, length, ROMENTRYTYPE_ROM | romflags );
572579                     }
573580                  }
574581               }

Previous 15994 Revisions Next


© 1998-2018 The MESS Team