Merge branch 'bugfix/esp_efuse_get_pkg_ver_v3.3' into 'release/v3.3'

efuse: Fix excess data coming from uninitialized variable (backport v3.3)

See merge request idf/esp-idf!4794
This commit is contained in:
Jiang Jiang Jian 2019-04-16 20:33:36 +08:00
commit 7a7128c7a3

View File

@ -39,7 +39,7 @@ uint8_t esp_efuse_get_chip_ver(void)
// Returns chip package from efuse // Returns chip package from efuse
uint32_t esp_efuse_get_pkg_ver(void) uint32_t esp_efuse_get_pkg_ver(void)
{ {
uint32_t pkg_ver; uint32_t pkg_ver = 0;
esp_efuse_read_field_blob(ESP_EFUSE_CHIP_VER_PKG, &pkg_ver, 3); esp_efuse_read_field_blob(ESP_EFUSE_CHIP_VER_PKG, &pkg_ver, 3);
return pkg_ver; return pkg_ver;
} }