summaryrefslogtreecommitdiff
path: root/util-linux
diff options
context:
space:
mode:
authorDenys Vlasenko2010-05-19 17:01:29 +0200
committerDenys Vlasenko2010-05-19 17:01:29 +0200
commitdc1fd2e52aa7d24fd609399e94b78c8c4dd79229 (patch)
treea9a9dbbf2e248ce579d632f583bd9f86718a3c90 /util-linux
parent9f82d0be615540ffc1fe4551750e6cb0bc76f737 (diff)
downloadbusybox-dc1fd2e52aa7d24fd609399e94b78c8c4dd79229.zip
busybox-dc1fd2e52aa7d24fd609399e94b78c8c4dd79229.tar.gz
mount: handle EDQUOT > 255 properly. closes bug 1579
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'util-linux')
-rw-r--r--util-linux/mount.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/util-linux/mount.c b/util-linux/mount.c
index 8ec3071..aed6f79 100644
--- a/util-linux/mount.c
+++ b/util-linux/mount.c
@@ -749,7 +749,15 @@ static const uint8_t nfs_err_stat[] = {
19, 20, 21, 22, 27, 28,
30, 63, 66, 69, 70, 71
};
-static const uint8_t nfs_err_errnum[] = {
+#if ( \
+ EPERM | ENOENT | EIO | ENXIO | EACCES| EEXIST | \
+ ENODEV| ENOTDIR | EISDIR | EINVAL| EFBIG | ENOSPC | \
+ EROFS | ENAMETOOLONG| ENOTEMPTY| EDQUOT| ESTALE| EREMOTE) < 256
+typedef uint8_t nfs_err_type;
+#else
+typedef uint16_t nfs_err_type;
+#endif
+static const nfs_err_type nfs_err_errnum[] = {
EPERM , ENOENT , EIO , ENXIO , EACCES, EEXIST,
ENODEV, ENOTDIR , EISDIR , EINVAL, EFBIG , ENOSPC,
EROFS , ENAMETOOLONG, ENOTEMPTY, EDQUOT, ESTALE, EREMOTE