fs/Path: rename to AllocatedPath

The new class Path only holds a string pointer without being
responsible for allocation/deallocation.  The FileSystem.hxx library
accepts Path arguments instead of AllocatedPath, to avoid forcing
callers to allocate another string object.
This commit is contained in:
Max Kellermann
2013-10-17 21:59:35 +02:00
parent b3611524f4
commit abfbd55305
51 changed files with 621 additions and 394 deletions

View File

@@ -27,7 +27,7 @@
#include <array>
#include <vector>
class Path;
class AllocatedPath;
class Error;
struct block_param {
@@ -109,10 +109,10 @@ struct config_param {
* Same as config_dup_path(), but looks up the setting in the
* specified block.
*/
Path GetBlockPath(const char *name, const char *default_value,
Error &error) const;
AllocatedPath GetBlockPath(const char *name, const char *default_value,
Error &error) const;
Path GetBlockPath(const char *name, Error &error) const;
AllocatedPath GetBlockPath(const char *name, Error &error) const;
gcc_pure
unsigned GetBlockValue(const char *name, unsigned default_value) const;