diff options
author | Peng Fan <peng.fan@nxp.com> | 2016-01-14 17:14:00 +0800 |
---|---|---|
committer | fang hui <hui.fang@freescale.com> | 2016-03-16 13:48:14 +0800 |
commit | acbb1597a85cff564942a296c04df8c489fa6904 (patch) | |
tree | 3e253522200c0bb4a60fc910cf80e4fa57079889 /common/env_callback.c | |
parent | 7d5fdf0be6b789662a28f259e2f7e5033a42b232 (diff) | |
download | u-boot-imx-acbb1597a85cff564942a296c04df8c489fa6904.zip u-boot-imx-acbb1597a85cff564942a296c04df8c489fa6904.tar.gz u-boot-imx-acbb1597a85cff564942a296c04df8c489fa6904.tar.bz2 |
MLK-12199 common:env fix unintialized scalar value
Reported by coverity ID: 17900 17902
Using uninitialized value e. Field e.flags is uninitialized when calling hsearch_r
Signed-off-by: Peng Fan <peng.fan@nxp.com>
Diffstat (limited to 'common/env_callback.c')
-rw-r--r-- | common/env_callback.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/common/env_callback.c b/common/env_callback.c index 7de88fb..c7f002a 100644 --- a/common/env_callback.c +++ b/common/env_callback.c @@ -98,6 +98,7 @@ static int set_callback(const char *name, const char *value) e.key = name; e.data = NULL; e.callback = NULL; + e.flags = 0; hsearch_r(e, FIND, &ep, &env_htab, 0); /* does the env variable actually exist? */ |