Previous 15994 Revisions Next

r12657 Thursday 18th August, 2011 at 10:42:39 UTC by Miodrag Milanović
Small cleanup (no whatsnew)
[src/emu]audit.c

src/emu/audit.c
r12656r12657
8383   int required = 0;
8484   int sharedFound = 0;
8585   int sharedRequired = 0;
86   //for (const rom_source *source = rom_first_source(m_enumerator.config()); source != NULL; source = rom_next_source(*source))
86
8787   const rom_source *source = rom_first_source(m_enumerator.config());
8888   {
8989      // determine the search path for this source and iterate through the regions
r12656r12657
164164
165165   // store validation for later
166166   m_validation = validation;
167
168   // iterate over ROM sources and regions
169   int found = 0;
170   int required = 0;
171   // determine the search path for this source and iterate through the regions
172167   m_searchpath = device->shortname();
173168
174169   // now iterate over regions and ROMs within
r12656r12657
176171   {
177172      for (const rom_entry *rom = rom_first_file(region); rom; rom = rom_next_file(rom))
178173      {
179         hash_collection hashes(ROM_GETHASHDATA(rom));
180         
181         // count the number of files with hashes
182         if (!hashes.flag(hash_collection::FLAG_NO_DUMP) && !ROM_ISOPTIONAL(rom))
183         {
184            required++;
185         }
186
187174         // audit a file
188175         audit_record *record = NULL;
189176         if (ROMREGION_ISROMDATA(region))
r12656r12657
192179         // audit a disk
193180         else if (ROMREGION_ISDISKDATA(region))
194181            record = audit_one_disk(rom);
195
196         // count the number of files that are found.
197         if (record != NULL && (record->status() == audit_record::STATUS_GOOD || (record->status() == audit_record::STATUS_FOUND_INVALID && also_used_by_parent(record->actual_hashes(), record->actual_length()) < 0)))
198         {
199            found++;
200         }
201182      }
202183   }
203184

Previous 15994 Revisions Next


© 1998-2018 The MESS Team