about summary refs log tree commit diff homepage
diff options
context:
space:
mode:
-rwxr-xr-xserver.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/server.c b/server.c
index a32ada5..9724359 100755
--- a/server.c
+++ b/server.c
@@ -34,6 +34,11 @@ static void tilesMap(void) {
 
     tiles = mmap(NULL, TILES_SIZE, PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0);
     if (tiles == MAP_FAILED) err(EX_OSERR, "mmap");
+
+#ifdef MADV_NOCORE
+    error = madvise(tiles, TILES_SIZE, MADV_NOCORE);
+    if (error) err(EX_OSERR, "madvise");
+#endif
 }
 
 static struct Tile *tileGet(uint32_t tileX, uint32_t tileY) {
png.h?id=42fcb6656dd9b6c735b09ce61f8ce4e875329c43&follow=1'>Compress PNG data in imageJune McEnroe 2019-01-07madvise MADV_NOCORE in imageJune McEnroe 2019-01-07Add license notice to explore JavaScriptJune McEnroe 2019-01-07Add Q/Home binding in exploreJune McEnroe 2019-01-07Fix explore image URLJune McEnroe 2019-01-07Add HOME button, ssh link, AGPL notice to exploreJune McEnroe 2019-01-06Add meta viewport to exploreJune McEnroe 2019-01-06Set background and max-width in exploreJune McEnroe 2019-01-06Swallow writes after the connection is closedJune McEnroe 2019-01-06Handle KCGI_HUPJune McEnroe 2019-01-06Install html filesJune McEnroe