rtc_module: fix build failure if assertions are disabled

Closes https://github.com/espressif/esp-idf/issues/1841

Signed-off-by: Mahavir Jain <mahavir@espressif.com>
This commit is contained in:
Mahavir Jain 2018-04-17 10:39:36 +05:30
parent a21336eaa1
commit 959c677025

View file

@ -1240,7 +1240,7 @@ static int adc_convert( adc_unit_t unit, int channel)
adc_value = SENS.sar_meas_start2.meas2_data_sar;
} else {
ESP_LOGE(TAG, "invalid adc unit");
assert(0);
return ESP_ERR_INVALID_ARG;
}
return adc_value;
}