summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 1b8f812)
raw | patch | inline | side by side (parent: 1b8f812)
author | oetiker <oetiker@a5681a0c-68f1-0310-ab6d-d61299d08faa> | |
Sun, 16 Sep 2007 15:35:11 +0000 (15:35 +0000) | ||
committer | oetiker <oetiker@a5681a0c-68f1-0310-ab6d-d61299d08faa> | |
Sun, 16 Sep 2007 15:35:11 +0000 (15:35 +0000) |
src/rrd_open.c | patch | blob | history |
diff --git a/src/rrd_open.c b/src/rrd_open.c
index 70e0ab9f5d6b38dd3b4339a438943f848e8c25d1..6a3cf34a8286fc6cc39b5f124f04a543a95b4399 100644 (file)
--- a/src/rrd_open.c
+++ b/src/rrd_open.c
When we stop reading, it is highly unlikely that we start up again.
In this manner we actually save time and diskaccess (and buffer cache).
Thanks to Dave Plonka for the Idea of using POSIX_FADV_RANDOM here. */
- if (0 != posix_fadvise(rrd_file->fd, 0, 0, POSIX_FADV_RANDOM)) {
- rrd_set_error("setting POSIX_FADV_RANDOM on '%s': %s", file_name,
- rrd_strerror(errno));
- goto out_close;
- }
+ posix_fadvise(rrd_file->fd, 0, 0, POSIX_FADV_RANDOM);
#endif
/*