From 437dca8b2f05a83e5c1df41226992c8d68b80007 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Sat, 25 Sep 2010 14:35:53 +0200 Subject: [PATCH] readahead: never readahead temporary files since their names tend not to be stable --- src/readahead-collect.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/readahead-collect.c b/src/readahead-collect.c index 47095b1f..c8490b5d 100644 --- a/src/readahead-collect.c +++ b/src/readahead-collect.c @@ -324,8 +324,10 @@ static int collect(const char *root) { if ((k = readlink_malloc(fn, &p)) >= 0) { - if (hashmap_get(files, p)) - /* Already read */ + if (startswith(p, "/tmp") || + hashmap_get(files, p)) + /* Not interesting, or + * already read */ free(p); else { unsigned long ul; -- 2.39.5