aboutsummaryrefslogtreecommitdiff
path: root/isofs
diff options
context:
space:
mode:
authorSergey Bugaev <bugaevc@gmail.com>2021-05-21 13:35:11 +0300
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2022-08-10 22:04:01 +0200
commit033397a36ab5bf40d7184791e036fae781355a21 (patch)
treea047493c88ddf558388eaf96b07459883a708976 /isofs
parentb15326a788615988df10d4f2dbe39190126135d6 (diff)
downloadhurd-033397a36ab5bf40d7184791e036fae781355a21.tar.gz
hurd-033397a36ab5bf40d7184791e036fae781355a21.tar.bz2
hurd-033397a36ab5bf40d7184791e036fae781355a21.zip
isofs: Assert we're only supposed to provide a read-only pager
Diffstat (limited to 'isofs')
-rw-r--r--isofs/pager.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/isofs/pager.c b/isofs/pager.c
index 259581e8..c2da2c0b 100644
--- a/isofs/pager.c
+++ b/isofs/pager.c
@@ -169,6 +169,9 @@ diskfs_get_filemap (struct node *np, vm_prot_t prot)
assert_backtrace (S_ISDIR (np->dn_stat.st_mode)
|| S_ISREG (np->dn_stat.st_mode)
|| S_ISLNK (np->dn_stat.st_mode));
+
+ /* We only support read-only pagers. */
+ assert_backtrace (prot == VM_PROT_READ);
pthread_spin_lock (&node2pagelock);