The manipulation of `bitidx` in Adafruit_DHT will eventually cause a segfault. If `readDHT` is called repeatedly, this line: ``` bits[bitidx++] = counter; ``` ...will eventually increment `bitidx` beyond the end of the `bits` array. This code (and the `bits` array) appear to be unused except for debugging and can be safely removed.
The manipulation of
bitidxin Adafruit_DHT will eventually cause a segfault. IfreadDHTis called repeatedly, this line:...will eventually increment
bitidxbeyond the end of thebitsarray.This code (and the
bitsarray) appear to be unused except for debugging and can be safely removed.