summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 1eb9f17)
raw | patch | inline | side by side (parent: 1eb9f17)
author | oetiker <oetiker@a5681a0c-68f1-0310-ab6d-d61299d08faa> | |
Thu, 28 May 2009 05:25:32 +0000 (05:25 +0000) | ||
committer | oetiker <oetiker@a5681a0c-68f1-0310-ab6d-d61299d08faa> | |
Thu, 28 May 2009 05:25:32 +0000 (05:25 +0000) |
src/rrd_open.c | patch | blob | history |
diff --git a/src/rrd_open.c b/src/rrd_open.c
index 59526d8b4c3ae3c49582afbd6da2ee440e500123..d09f640daa681c1f2075e4481a54ff6f1b1fc8dd 100644 (file)
--- a/src/rrd_open.c
+++ b/src/rrd_open.c
#ifdef USE_MADVISE
if (rdwr & RRD_COPY) {
/* We will read everything in a moment (copying) */
- madvise(data, rrd_file->file_len, MADV_WILLNEED | MADV_SEQUENTIAL);
+ madvise(data, rrd_file->file_len, MADV_WILLNEED );
+ madvise(data, rrd_file->file_len, MADV_SEQUENTIAL );
} else {
/* We do not need to read anything in for the moment */
madvise(data, rrd_file->file_len, MADV_RANDOM);
/* the stat_head will be needed soonish, so hint accordingly */
- madvise(data, sizeof(stat_head_t), MADV_WILLNEED | MADV_RANDOM);
+ madvise(data, sizeof(stat_head_t), MADV_WILLNEED);
+ madvise(data, sizeof(stat_head_t), MADV_RANDOM);
}
#endif