path-util.h revision 85eca92e2061043d733991b386d8dc10fad0fc30
#pragma once
along with systemd; If not, see <http://www.gnu.org/licenses/>.
#include <stdbool.h>
#include "macro.h"
#include "time-util.h"
#ifdef HAVE_SPLIT_USR
char** path_split_and_make_absolute(const char *p);
char* path_make_absolute_cwd(const char *p);
bool path_equal_or_files_same(const char *a, const char *b);
char** path_strv_make_absolute_cwd(char **l);
for (char *_slash = ({ path_kill_slashes(strcpy(prefix, path)); streq(prefix, "/") ? NULL : strrchr(prefix, '/'); }); _slash && ((*_slash = 0), true); _slash = strrchr((prefix), '/'))
for (char *_slash = ({ path_kill_slashes(strcpy(prefix, path)); if (streq(prefix, "/")) prefix[0] = 0; strrchr(prefix, 0); }); _slash && ((*_slash = 0), true); _slash = strrchr((prefix), '/'))
_path ++; \
_p--; \
_ret; \