f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poettering This file is part of systemd.
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poettering Copyright 2010 Lennart Poettering
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poettering systemd is free software; you can redistribute it and/or modify it
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poettering under the terms of the GNU Lesser General Public License as published by
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poettering the Free Software Foundation; either version 2.1 of the License, or
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poettering (at your option) any later version.
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poettering systemd is distributed in the hope that it will be useful, but
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poettering WITHOUT ANY WARRANTY; without even the implied warranty of
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poettering MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poettering Lesser General Public License for more details.
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poettering You should have received a copy of the GNU Lesser General Public License
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poettering along with systemd; If not, see <http://www.gnu.org/licenses/>.
3ffd4af22052963e7a29431721ee204e634bea75Lennart Poetteringint rmdir_parents(const char *path, const char *stop);
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poetteringint rename_noreplace(int olddirfd, const char *oldpath, int newdirfd, const char *newpath);
095b30cbf976b6c82a10c16bef76fa5b4c03f658Zbigniew Jędrzejewski-Szmekint readlinkat_malloc(int fd, const char *p, char **ret);
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poetteringint readlink_malloc(const char *p, char **r);
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poetteringint readlink_value(const char *p, char **ret);
ebc05a09ad6d1672cf4f426ee4252cf495daa139Harald Hoyerint readlink_and_make_absolute(const char *p, char **r);
ebc05a09ad6d1672cf4f426ee4252cf495daa139Harald Hoyerint readlink_and_canonicalize(const char *p, char **r);
768100efd57ffbbefe9beaa33d1dd5ecc7f69173Lennart Poetteringint readlink_and_make_absolute_root(const char *root, const char *path, char **ret);
768100efd57ffbbefe9beaa33d1dd5ecc7f69173Lennart Poetteringint chmod_and_chown(const char *path, mode_t mode, uid_t uid, gid_t gid);
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poetteringint fchmod_and_fchown(int fd, mode_t mode, uid_t uid, gid_t gid);
d514feaa872820d5cb4e9321ad32673c09fbb3f4Thomas Hindoe Paaboel Andersenint fchmod_umask(int fd, mode_t mode);
095b30cbf976b6c82a10c16bef76fa5b4c03f658Zbigniew Jędrzejewski-Szmekint fd_warn_permissions(const char *path, int fd);
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poettering#define laccess(path, mode) faccessat(AT_FDCWD, (path), (mode), AT_SYMLINK_NOFOLLOW)
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poetteringint touch_file(const char *path, bool parents, usec_t stamp, uid_t uid, gid_t gid, mode_t mode);
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poetteringint symlink_idempotent(const char *from, const char *to);
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poetteringint symlink_atomic(const char *from, const char *to);
98f59e59e0c31ffcb953d3a7dba0da5e6f2f55f7Harald Hoyerint mknod_atomic(const char *path, mode_t mode, dev_t dev);
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poetteringint mkfifo_atomic(const char *path, mode_t mode);
98f59e59e0c31ffcb953d3a7dba0da5e6f2f55f7Harald Hoyerint get_files_in_directory(const char *path, char ***list);
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poettering#define INOTIFY_EVENT_MAX (sizeof(struct inotify_event) + NAME_MAX + 1)
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poettering#define FOREACH_INOTIFY_EVENT(e, buffer, sz) \
f73141d7657b3f60b8669bc8386413d8a8a372c6Lennart Poettering (uint8_t*) (e) < (uint8_t*) (buffer.raw) + (sz); \
98f59e59e0c31ffcb953d3a7dba0da5e6f2f55f7Harald Hoyer (e) = (struct inotify_event*) ((uint8_t*) (e) + sizeof(struct inotify_event) + (e)->len))