image: fix getenv_bootm_size() function