summaryrefslogtreecommitdiff
path: root/test/testmmap.c
diff options
context:
space:
mode:
authorrbb <rbb@13f79535-47bb-0310-9956-ffa450edef68>2000-12-07 05:00:28 +0000
committerrbb <rbb@13f79535-47bb-0310-9956-ffa450edef68>2000-12-07 05:00:28 +0000
commitc87cdcea7902217002ece8e5a967600ec12b38d6 (patch)
treea8f88943ab4b3e3e6751caa0d64007fb6984cbe1 /test/testmmap.c
parent362f16c2e71a3db80be3bd2584e833ed77478233 (diff)
downloadlibapr-c87cdcea7902217002ece8e5a967600ec12b38d6.tar.gz
Allow APR programmers to determine if an MMAP is read-only or if it should
be write-able. Submitted by: Ryan Bloom and Will Rowe git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@60908 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'test/testmmap.c')
-rw-r--r--test/testmmap.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/test/testmmap.c b/test/testmmap.c
index 97eb64166..955d1276c 100644
--- a/test/testmmap.c
+++ b/test/testmmap.c
@@ -52,6 +52,7 @@
* <http://www.apache.org/>.
*/
+#include <unistd.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
@@ -116,7 +117,7 @@ int main(void)
}
fprintf(stdout,"Trying to mmap the file.............");
- if (apr_mmap_create(&themmap, thefile, 0, finfo.size, context) != APR_SUCCESS) {
+ if (apr_mmap_create(&themmap, thefile, 0, finfo.size, APR_MMAP_READ, context) != APR_SUCCESS) {
fprintf(stderr,"Failed!\n");
exit(-1);
}