thermferm/one-wire.c

changeset 661
8c1e7a52e24f
parent 660
a28ef4d9afa4
child 662
56c72393ca26
equal deleted inserted replaced
660:a28ef4d9afa4 661:8c1e7a52e24f
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;

mercurial