mirror of
https://github.com/espressif/esp-idf.git
synced 2025-08-04 13:14:32 +02:00
fix(usb): fix warnings found by GNU static analyzer
This commit is contained in:
@@ -395,8 +395,10 @@ esp_err_t usb_new_phy(const usb_phy_config_t *config, usb_phy_handle_t *handle_r
|
||||
return ESP_OK;
|
||||
|
||||
cleanup:
|
||||
free(phy_context->iopins);
|
||||
free(phy_context);
|
||||
if (phy_context) {
|
||||
free(phy_context->iopins);
|
||||
free(phy_context);
|
||||
}
|
||||
if (p_phy_ctrl_obj->ref_count == 0) {
|
||||
free(p_phy_ctrl_obj);
|
||||
p_phy_ctrl_obj = NULL;
|
||||
|
Reference in New Issue
Block a user