aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/libmtd_legacy.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/libmtd_legacy.c b/lib/libmtd_legacy.c
index 97fef04..2b7f65f 100644
--- a/lib/libmtd_legacy.c
+++ b/lib/libmtd_legacy.c
@@ -235,6 +235,8 @@ int legacy_get_mtd_oobavail(const char *node)
ret = ioctl(fd, ECCGETLAYOUT, &usrlay);
if (ret < 0) {
+ if (errno == EOPNOTSUPP)
+ goto out_close;
sys_errmsg("ECCGETLAYOUT ioctl request failed");
goto out_close;
}