Skip to content

Commit

Permalink
Memory Leak
Browse files Browse the repository at this point in the history
Release EventGroup, Heap Memory for dq
  • Loading branch information
stickbreaker authored Nov 25, 2017
1 parent 89ab899 commit 20ba765
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion cores/esp32/esp32-hal-i2c.c
Original file line number Diff line number Diff line change
Expand Up @@ -1130,7 +1130,11 @@ if(i2c->intr_handle){
// log_e("released ISR=%d",error);
i2c->intr_handle=NULL;
}
return I2C_ERROR_OK;
if(i2c->i2c_event){
xEventGroupDelete(i2c->i2c_event);
i2c->i2c_event = NULL;
}
return i2cFreeQueue(i2c); //release dynamic memory
}

/* todo
Expand Down

0 comments on commit 20ba765

Please sign in to comment.