fs/AllocatedPath: make the nullptr_t constructor public

This commit is contained in:
Max Kellermann
2018-01-17 12:17:41 +01:00
parent c4f7740b80
commit bbc5212436
24 changed files with 58 additions and 62 deletions

View File

@@ -316,7 +316,7 @@ CompositeStorage::MapFS(const char *uri) const noexcept
auto f = FindStorage(uri);
if (f.directory->storage == nullptr)
return AllocatedPath::Null();
return nullptr;
return f.directory->storage->MapFS(f.uri);
}

View File

@@ -25,7 +25,7 @@
AllocatedPath
Storage::MapFS(gcc_unused const char *uri_utf8) const noexcept
{
return AllocatedPath::Null();
return nullptr;
}
AllocatedPath

View File

@@ -66,7 +66,7 @@ public:
/**
* Map the given relative URI to a local file path. Returns
* AllocatedPath::Null() on error or if this storage does not
* nullptr on error or if this storage does not
* support local files.
*/
gcc_pure

View File

@@ -124,7 +124,7 @@ LocalStorage::MapFS(const char *uri_utf8) const noexcept
try {
return MapFSOrThrow(uri_utf8);
} catch (...) {
return AllocatedPath::Null();
return nullptr;
}
}