aboutsummaryrefslogtreecommitdiffstats
path: root/src/fs/AllocatedPath.hxx (unfollow)
Commit message (Collapse)AuthorFilesLines
2013-10-21fs/AllocatedPath: don't include glib.hMax Kellermann1-4/+0
2013-10-17fs/Path: rename to AllocatedPathMax Kellermann1-27/+37
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.
2013-10-17fs/Path: move definitions to struct PathTraitsMax Kellermann1-52/+5
2013-10-17fs/Path: include clenaupMax Kellermann1-1/+1
2013-10-17fs/Charset: don't allow nullptr argumentsMax Kellermann1-2/+2
2013-10-17fs/Path: move configuration code to Config.cxxMax Kellermann1-20/+2
2013-10-17fs/Path: move path_domain to Domain.hxxMax Kellermann1-2/+0
2013-10-17fs/Path: include cleanupMax Kellermann1-1/+0
2013-10-17fs/Path: move MPD_PATH_MAX to Limits.hxxMax Kellermann1-13/+0
2013-10-15gcc.h: rename to Compiler.hMax Kellermann1-1/+1
2013-10-14fs/Path: add method IsAbsolute()Max Kellermann1-0/+31
2013-10-14fs/Path: add separator constants/functionsMax Kellermann1-0/+29
2013-10-14fs/Path: add method RelativeFS()Max Kellermann1-0/+9
Move code from map_fs_to_utf8().
2013-10-14fs/Path: add method data()Max Kellermann1-0/+9
2013-10-02filesystem/Path: use std::stringMax Kellermann1-78/+23
2013-09-12Path: add FromUTF8() overload that returns an ErrorMax Kellermann1-0/+5
2013-09-12ConfigPath: move path_domain to system/Path.cxxMax Kellermann1-0/+2
2013-02-02Path.hxx: add GetDirectoryName() methodDenis Krjuchkov1-0/+9
2013-01-28Path::FromUTF8() returns nulled instance on error, add error handling where ↵Denis Krjuchkov1-4/+1
required
2013-01-28Path: convert remaining funcs to methods, keep fs_charset as std::stringDenis Krjuchkov1-6/+10
2013-01-28Path: merge utf8_to_fs_charset() into Path::FromUTF8()Denis Krjuchkov1-10/+2
2013-01-28Path: convert fs_charset_to_utf8() to static method Path::ToUTF8()Denis Krjuchkov1-8/+10
2013-01-26Path: define MPD_PATH_MAX to 260 on WindowsDenis Krjuchkov1-1/+3
2013-01-26Path: ToUTF() returns std::stringDenis Krjuchkov1-8/+5
2013-01-22Path: move to fs subdirectoryDenis Krjuchkov1-2/+2
2013-01-18Path: new class "Path" wraps filesystem path stringsMax Kellermann1-0/+207
2013-01-17path: convert to C++Max Kellermann1-6/+8
2011-01-29copyright year 2011Max Kellermann1-1/+1
2009-12-31Update copyright notices.Avuton Olrich1-1/+1
2009-03-13all: Update copyright header.Avuton Olrich1-6/+7
This updates the copyright header to all be the same, which is pretty much an update of where to mail request for a copy of the GPL and the years of the MPD project. This also puts all committers under 'The Music Player Project' umbrella. These entries should go individually in the AUTHORS file, for consistancy.
2009-02-20path: don't export path_set_fs_charset()Max Kellermann1-2/+0
The function path_set_fs_charset() is only used in path.c.
2009-01-08path: include cleanupMax Kellermann1-1/+0
2009-01-08path: allocate buffer in fs_charset conversion functionsMax Kellermann1-2/+12
Don't use fixed static buffers. GLib allocates a new string for us anyway, let's just return this one instead of copying it.
2009-01-04path: removed pfx_dir()Max Kellermann1-12/+0
Use GLib's g_build_filename() instead of pfx_dir().
2008-12-29removed os_compat.hMax Kellermann1-1/+2
Only include headers which are really needed. os_compat.h aimed to make MPD easily portable, but was never actually made portable.
2008-11-05path: no CamelCaseMax Kellermann1-4/+4
Rename variables and functions.
2008-10-31path: removed sanitizePathDup()Max Kellermann1-3/+0
We don't need to sanitize the path, because the mapper already checks for malformed paths.
2008-10-31path: moved playlist_dir to mapper.cMax Kellermann1-9/+0
Added the function map_spl_utf8_to_fs() which replaces utf8_to_fs_playlist_path().
2008-10-31added prefix to header macrosMax Kellermann1-2/+2
"LOG_H" is a macro which is also used by ffmpeg/log.h. This is ffmpeg's fault, because short macros should be reserved for applications, but since it's always a good idea to choose prefixed macro names, even for applications, we are going to do that in MPD.
2008-10-20path: removed pathcpy_trunc()Max Kellermann1-6/+0
There was only one user of pathcpy_trunc(), which can be eliminated.
2008-10-20path: replaced parent_path() with g_path_get_dirname()Max Kellermann1-10/+0
Again, GLib's version is more robust than ours.
2008-10-20path: replaced mpd_basename() with g_path_get_basename()Max Kellermann1-8/+0
GLib's g_path_get_basename() is much more reliable than mpd_basename(). The latter could be tricked into an assertion failure.
2008-10-15mapper: moved musicDir initialization from path.cMax Kellermann1-5/+0
Moved the musicDir variable and its initialization code from path.c to mapper.c.
2008-09-29path: add mpd_basename() functionEric Wong1-0/+8
This is like basename(3) but with predictable semantics independent of C library or build options used. This is also much more strict and does not account for trailing slashes (mpd should never deal with trailing slashes on internal functions).
2008-04-12clean up CPP includesMax Kellermann1-1/+0
Try to only include headers which are really needed. We should particularly check all "headers including other headers". The long-term goal is to have a manageable, small API for plugins (decoders, output) without so many mpd internals cluttering the namespace. git-svn-id: https://svn.musicpd.org/mpd/trunk@7319 09075e82-0dd4-0310-85a5-a0d7c8717e4f
2008-02-05fix -Wconst warningsMax Kellermann1-5/+5
[ew: cleaned up the dirty union hack a bit] Signed-off-by: Eric Wong <normalperson@yhbt.net> git-svn-id: https://svn.musicpd.org/mpd/trunk@7180 09075e82-0dd4-0310-85a5-a0d7c8717e4f
2008-01-03Cleanup #includes of standard system headers and put them in one placeEric Wong1-3/+1
This will make refactoring features easier, especially now that pthreads support and larger refactorings are on the horizon. Hopefully, this will make porting to other platforms (even non-UNIX-like ones for masochists) easier, too. os_compat.h will house all the #includes for system headers considered to be the "core" of MPD. Headers for optional features will be left to individual source files. git-svn-id: https://svn.musicpd.org/mpd/trunk@7130 09075e82-0dd4-0310-85a5-a0d7c8717e4f
2008-01-03document parent_path()Eric Wong1-3/+10
git-svn-id: https://svn.musicpd.org/mpd/trunk@7128 09075e82-0dd4-0310-85a5-a0d7c8717e4f
2008-01-01Make utf8_to_fs_playlist_path universally accessibleEric Wong1-1/+7
git-svn-id: https://svn.musicpd.org/mpd/trunk@7115 09075e82-0dd4-0310-85a5-a0d7c8717e4f
2007-12-28Merge branches/ew r7104Eric Wong1-17/+29
thread-safety work in preparation for rewrite to use pthreads Expect no regressions against trunk (r7078), possibly minor performance improvements in update (due to fewer heap allocations), but increased stack usage. Applied the following patches: * maxpath_str for reentrancy (temporary fix, reverted) * path: start working on thread-safe variants of these methods * Re-entrancy work on path/character-set conversions * directory.c: exploreDirectory() use reentrant functions here * directory/update: more use of reentrant functions + cleanups * string_toupper: a strdup-less version of strDupToUpper * get_song_url: a static-variable-free version of getSongUrl() * Use reentrant/thread-safe get_song_url everywhere * replace rmp2amp with the reentrant version, rmp2amp_r * Get rid of the non-reentrant/non-thread-safe rpp2app, too. * buffer2array: assert strdup() returns a usable value in unit tests * replace utf8ToFsCharset and fsCharsetToUtf8 with thread-safe variants * fix storing playlists w/o absolute paths * parent_path(), a reentrant version of parentPath() * parentPath => parent_path for reentrancy and thread-safety * allow "make test" to automatically run embedded unit tests * remove convStrDup() and maxpath_str() * use MPD_PATH_MAX everywhere instead of MAXPATHLEN * path: get rid of appendSlash, pfx_path and just use pfx_dir * get_song_url: fix the ability to play songs in the top-level music_directory git-svn-id: https://svn.musicpd.org/mpd/trunk@7106 09075e82-0dd4-0310-85a5-a0d7c8717e4f