diff --git a/src/storage/CompositeStorage.cxx b/src/storage/CompositeStorage.cxx index e28cb487a..bc0b9d56e 100644 --- a/src/storage/CompositeStorage.cxx +++ b/src/storage/CompositeStorage.cxx @@ -287,7 +287,8 @@ CompositeStorage::GetInfo(const char *uri, bool follow, StorageFileInfo &info, return true; } - error.Set(composite_domain, "No such directory"); + if (!error.IsDefined()) + error.Set(composite_domain, "No such directory"); return false; }