diff options
author | Wolfgang Denk <wd@denx.de> | 2010-08-18 21:19:00 +0200 |
---|---|---|
committer | Wolfgang Denk <wd@denx.de> | 2010-08-18 21:19:00 +0200 |
commit | 5549d22b656550d36b2cc46743c7220ab0e9dcc4 (patch) | |
tree | acc88f5980b8ca5999e05e9a86429e5b397cdd7e /common/env_nand.c | |
parent | ae37a0704a8a27e47471f541a68b88370cd14aa8 (diff) | |
parent | 9ce2c4b7f79c5bdc1697a6979a0d33e51c3cf57d (diff) | |
download | u-boot-imx-5549d22b656550d36b2cc46743c7220ab0e9dcc4.zip u-boot-imx-5549d22b656550d36b2cc46743c7220ab0e9dcc4.tar.gz u-boot-imx-5549d22b656550d36b2cc46743c7220ab0e9dcc4.tar.bz2 |
Merge branch 'master' of /home/wd/git/u-boot/master
Diffstat (limited to 'common/env_nand.c')
-rw-r--r-- | common/env_nand.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/common/env_nand.c b/common/env_nand.c index a5e1038..d38bcca 100644 --- a/common/env_nand.c +++ b/common/env_nand.c @@ -266,6 +266,8 @@ int readenv (size_t offset, u_char * buf) u_char *char_ptr; blocksize = nand_info[0].erasesize; + if (!blocksize) + return 1; len = min(blocksize, CONFIG_ENV_SIZE); while (amount_loaded < CONFIG_ENV_SIZE && offset < end) { |