Skip to content

Commit

Permalink
Fix #26: added missing returns for read(int pin, ...) and read2(int p…
Browse files Browse the repository at this point in the history
…in, ...) (#27)
  • Loading branch information
phd authored and winlinvip committed Oct 14, 2018
1 parent bf0eb33 commit 803181b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions SimpleDHT.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ int SimpleDHT::read(byte* ptemperature, byte* phumidity, byte pdata[40]) {

int SimpleDHT::read(int pin, byte* ptemperature, byte* phumidity, byte pdata[40]) {
setPin(pin);
read(ptemperature, phumidity, pdata);
return read(ptemperature, phumidity, pdata);
}

void SimpleDHT::setPin(int pin) {
Expand Down Expand Up @@ -185,7 +185,7 @@ int SimpleDHT11::read2(float* ptemperature, float* phumidity, byte pdata[40]) {

int SimpleDHT11::read2(int pin, float* ptemperature, float* phumidity, byte pdata[40]) {
setPin(pin);
read2(ptemperature, phumidity, pdata);
return read2(ptemperature, phumidity, pdata);
}

int SimpleDHT11::sample(byte data[40]) {
Expand Down Expand Up @@ -294,7 +294,7 @@ int SimpleDHT22::read2(float* ptemperature, float* phumidity, byte pdata[40]) {

int SimpleDHT22::read2(int pin, float* ptemperature, float* phumidity, byte pdata[40]) {
setPin(pin);
read2(ptemperature, phumidity, pdata);
return read2(ptemperature, phumidity, pdata);
}

int SimpleDHT22::sample(byte data[40]) {
Expand Down

0 comments on commit 803181b

Please sign in to comment.