}
int main(int argc, char** argv) {
- list<W1Device *> device_list;
- int round;
- long scan_interval;
- long store_interval;
- string loc;
- W1Device *device;
+ list<W1Device *> device_list;
+ int round;
+ long scan_interval;
+ long store_interval;
+ string loc;
+ W1Device *device;
+ list<W1Device *>::iterator iter;
// default values than can be overwritten with parameters
loc = "/tmp/w1data";
if (device_list.size() > 0) {
while(1) {
round++;
- for(list<W1Device *>::iterator list_iter = device_list.begin(); list_iter != device_list.end(); list_iter++) {
- device = (W1Device *)*list_iter;
+ for(iter = device_list.begin(); iter != device_list.end(); iter++) {
+ device = (W1Device *)*iter;
device->printout();
sleep(1);
if (round >= store_interval) {