From 96ae3319c5d51e46eebe3c7b3e3872bad3252928 Mon Sep 17 00:00:00 2001 From: Werner Almesberger Date: Sat, 26 Jan 2013 21:09:19 -0300 Subject: [PATCH] libubb/physmem.c (physmem_xlat): don't close the (supposedly) cached fd --- libubb/physmem.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/libubb/physmem.c b/libubb/physmem.c index db4de06..6be5c2f 100644 --- a/libubb/physmem.c +++ b/libubb/physmem.c @@ -148,7 +148,6 @@ int physmem_xlat(const void *v, size_t len, while (len) { if (n >= vec_len) { - close(fd); errno = EOVERFLOW; return -1; } @@ -163,7 +162,6 @@ int physmem_xlat(const void *v, size_t len, vaddr += this_len; len -= this_len; } - close(fd); return n; }