diff options
author | Joseph Hunkeler <jhunkeler@users.noreply.github.com> | 2024-12-11 10:28:47 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-12-11 10:28:47 -0500 |
commit | 3078519379ffcdc45811431336547d7df31a24ee (patch) | |
tree | 2b5be989ca839bd97f55f40605e23d7019397be7 /include/copy.h | |
parent | 456c5a481a7dabb53434a696488ac6eecb962d5b (diff) | |
parent | 4fd92ec6b203d6b94b9e9f9531fd60a65736e810 (diff) | |
download | stasis-3078519379ffcdc45811431336547d7df31a24ee.tar.gz |
Merge pull request #75 from jhunkeler/delivery-lib
Move delivery_*.c sources into their own library
Diffstat (limited to 'include/copy.h')
-rw-r--r-- | include/copy.h | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/include/copy.h b/include/copy.h deleted file mode 100644 index 0f92ddd..0000000 --- a/include/copy.h +++ /dev/null @@ -1,35 +0,0 @@ -//! @file copy.h -#ifndef STASIS_COPY_H - -#include <stdio.h> -#include <stdlib.h> -#include <string.h> -#include <dirent.h> -#include <errno.h> -#include <sys/stat.h> -#include <unistd.h> -#include "core.h" - -#define CT_OWNER 1 << 1 -#define CT_PERM 1 << 2 - -/** - * Copy a single file - * - * ```c - * if (copy2("/source/path/example.txt", "/destination/path/example.txt", CT_PERM | CT_OWNER)) { - * fprintf(stderr, "Unable to copy file\n"); - * exit(1); - * } - * ``` - * - * - * @param src source file path - * @param dest destination file path - * @param op CT_OWNER (preserve ownership) - * @param op CT_PERM (preserve permission bits) - * @return 0 on success, -1 on error - */ -int copy2(const char *src, const char *dest, unsigned op); - -#endif // STASIS_COPY_H
\ No newline at end of file |