From: Midnight Veil Date: Thu, 8 Jun 2023 07:11:37 +0000 (+1000) Subject: Translate POSIX errorcode EROFS to ISC_R_NOPERM X-Git-Tag: v9.19.15~29^2~1 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=dd6acc1cac3b0df8770641839fe0d000f4db611d;p=thirdparty%2Fbind9.git Translate POSIX errorcode EROFS to ISC_R_NOPERM Report "permission denied" instead of "unexpected error" when trying to update a zone file on a read-only file system. --- diff --git a/lib/isc/errno2result.c b/lib/isc/errno2result.c index a6646d2181b..1ef0c884d5e 100644 --- a/lib/isc/errno2result.c +++ b/lib/isc/errno2result.c @@ -45,6 +45,7 @@ isc___errno2result(int posixerrno, bool dolog, const char *file, return (ISC_R_FILENOTFOUND); case EACCES: case EPERM: + case EROFS: return (ISC_R_NOPERM); case EEXIST: return (ISC_R_FILEEXISTS);