Skip to content

Commit f1b82c7

Browse files
committed
Merge branch 'bugfix/build_fail_if_claiming_enabled' into 'master'
rmaker_core: Fixes build failure when claim config is disabled. See merge request app-frameworks/esp-rainmaker!191
2 parents d3f0e64 + 4517665 commit f1b82c7

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

components/esp_rainmaker/src/core/esp_rmaker_core.c

+4-1
Original file line numberDiff line numberDiff line change
@@ -264,7 +264,10 @@ static esp_err_t esp_rmaker_init(const esp_rmaker_config_t *config, bool use_cla
264264
ESP_LOGE(TAG, "Failed to initialise MQTT Config. Please perform \"claiming\" using RainMaker CLI.");
265265
return ESP_FAIL;
266266
} else {
267-
if (!esp_rmaker_priv_data->need_claim) {
267+
#ifdef ESP_RMAKER_CLAIM_ENABLED
268+
if (!esp_rmaker_priv_data->need_claim)
269+
#endif /* ESP_RMAKER_CLAIM_ENABLED */
270+
{
268271
if (esp_rmaker_mqtt_init(esp_rmaker_priv_data->mqtt_config) != ESP_OK) {
269272
esp_rmaker_deinit_priv_data(esp_rmaker_priv_data);
270273
esp_rmaker_priv_data = NULL;

0 commit comments

Comments
 (0)