From 2182209a8ac1ed2f0c80893ecac4d81fcab18e18 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Sun, 9 Feb 2014 10:46:57 +0100 Subject: db/update/Walk: disable FindAncestorLoop() if device/inode==0 --- src/db/update/Walk.cxx | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/db') diff --git a/src/db/update/Walk.cxx b/src/db/update/Walk.cxx index 44b10e2bd..2cb360bf6 100644 --- a/src/db/update/Walk.cxx +++ b/src/db/update/Walk.cxx @@ -163,6 +163,11 @@ FindAncestorLoop(Storage &storage, Directory *parent, unsigned inode, unsigned device) { #ifndef WIN32 + if (device == 0 && inode == 0) + /* can't detect loops if the Storage does not support + these numbers */ + return 0; + while (parent) { if (!parent->have_stat && !update_directory_stat(storage, *parent)) -- cgit v1.2.3