187 pthread_mutex_lock(&mutexes[LOCK_ONE_WIRE]); |
187 pthread_mutex_lock(&mutexes[LOCK_ONE_WIRE]); |
188 dev_w1->present = DEVPRESENT_NO; |
188 dev_w1->present = DEVPRESENT_NO; |
189 pthread_mutex_unlock(&mutexes[LOCK_ONE_WIRE]); |
189 pthread_mutex_unlock(&mutexes[LOCK_ONE_WIRE]); |
190 for (device = Config.devices; device; device = device->next) { |
190 for (device = Config.devices; device; device = device->next) { |
191 if (strcmp(dev_w1->address, device->address) == 0) { |
191 if (strcmp(dev_w1->address, device->address) == 0) { |
192 pthread_mutex_lock(&mutexes[LOCK_DEVICES]); |
192 // pthread_mutex_lock(&mutexes[LOCK_DEVICES]); |
193 device->present = DEVPRESENT_NO; |
193 device->present = DEVPRESENT_NO; |
194 pthread_mutex_unlock(&mutexes[LOCK_DEVICES]); |
194 // pthread_mutex_unlock(&mutexes[LOCK_DEVICES]); |
195 } |
195 } |
196 } |
196 } |
197 } |
197 } |
198 free(devfile); |
198 free(devfile); |
199 devfile = NULL; |
199 devfile = NULL; |