diff options
-rw-r--r-- | lib/libmtd_legacy.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libmtd_legacy.c b/lib/libmtd_legacy.c index d3f1672..1ae9946 100644 --- a/lib/libmtd_legacy.c +++ b/lib/libmtd_legacy.c @@ -262,7 +262,7 @@ int legacy_get_dev_info(const char *node, struct mtd_dev_info *mtd) mtd->mtd_num = mtd->minor / 2; - fd = open(node, O_RDWR); + fd = open(node, O_RDONLY); if (fd == -1) return sys_errmsg("cannot open \"%s\"", node); |