Fix some longstanding environment bugs

Sascha Hauer s.hauer at pengutronix.de
Wed Apr 9 00:39:22 PDT 2014


When an environment doesn't fit into the environment partition saveenv
still returned success. Also loading this corrupted partition resulted
in success. Fix this.

----------------------------------------------------------------
Sascha Hauer (4):
      unlink_recursive: return negative error value
      loadenv: ignore -ENOENT when removing /env
      saveenv: Properly detect write errors
      loadenv: detect truncated environment files

 commands/loadenv.c     |  2 +-
 common/environment.c   | 38 ++++++++++++++++++++++++++++----------
 lib/unlink-recursive.c |  2 +-
 3 files changed, 30 insertions(+), 12 deletions(-)



More information about the barebox mailing list