diff options
author | Fabio Priuli <etabeta78@users.noreply.github.com> | 2012-02-23 17:51:14 +0000 |
---|---|---|
committer | Fabio Priuli <etabeta78@users.noreply.github.com> | 2012-02-23 17:51:14 +0000 |
commit | 5607b591db96d1ac6de31b528ffd440421835482 (patch) | |
tree | 24ba6a4a2ceb5a0136651f4db74647e161eadbb5 | |
parent | 9e08266ba6c0ff93481476d98f8dd0317aeca7c2 (diff) |
info: made consistent the loops through subdevices. no whatsnew.
-rw-r--r-- | src/emu/info.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/emu/info.c b/src/emu/info.c index f20ed52b451..1844b8831a3 100644 --- a/src/emu/info.c +++ b/src/emu/info.c @@ -403,10 +403,9 @@ void info_xml_creator::output_devices() { // first, run through devices with roms which belongs to the default configuration device_iterator deviter(m_drivlist.config().root_device()); - deviter.first(); - for (device_t *device = deviter.next(); device != NULL; device = deviter.next()) + for (device_t *device = deviter.first(); device != NULL; device = deviter.next()) { - if (device->rom_region() != NULL && device->shortname()!= NULL) + if (device->owner() != NULL && device->rom_region() != NULL && device->shortname()!= NULL) { if (shortnames.add(device->shortname(), 0, FALSE) != TMERR_DUPLICATE) output_one_device(*device, device->tag()); @@ -449,8 +448,7 @@ void info_xml_creator::output_devices() void info_xml_creator::output_device_roms() { device_iterator deviter(m_drivlist.config().root_device()); - deviter.first(); - for (device_t *device = deviter.next(); device != NULL; device = deviter.next()) + for (device_t *device = deviter.first(); device != NULL; device = deviter.next()) if (device->owner() != NULL && device->rom_region() != NULL && device->shortname()!= NULL) fprintf(m_output, "\t\t<device_ref name=\"%s\"/>\n", xml_normalize_string(device->shortname())); } |