chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Change systemd occurences in factory/etc/pam.d to elogind.
[elogind.git]
/
src
/
shared
/
copy.c
diff --git
a/src/shared/copy.c
b/src/shared/copy.c
index f9ec6733bec7249f53fa87979616ec634a7bc91d..230e7e4d3fc3a793431fc5165a5c3631dbbf0d3b 100644
(file)
--- a/
src/shared/copy.c
+++ b/
src/shared/copy.c
@@
-285,7
+285,7
@@
static int fd_copy_directory(
else if (S_ISBLK(buf.st_mode) || S_ISCHR(buf.st_mode))
q = fd_copy_node(dirfd(d), de->d_name, &buf, fdt, de->d_name);
else
else if (S_ISBLK(buf.st_mode) || S_ISCHR(buf.st_mode))
q = fd_copy_node(dirfd(d), de->d_name, &buf, fdt, de->d_name);
else
- q = -E
NOTSU
P;
+ q = -E
OPNOTSUP
P;
if (q == -EEXIST && merge)
q = 0;
if (q == -EEXIST && merge)
q = 0;
@@
-317,7
+317,7
@@
int copy_tree_at(int fdf, const char *from, int fdt, const char *to, bool merge)
else if (S_ISBLK(st.st_mode) || S_ISCHR(st.st_mode))
return fd_copy_node(fdf, from, &st, fdt, to);
else
else if (S_ISBLK(st.st_mode) || S_ISCHR(st.st_mode))
return fd_copy_node(fdf, from, &st, fdt, to);
else
- return -E
NOTSU
P;
+ return -E
OPNOTSUP
P;
}
int copy_tree(const char *from, const char *to, bool merge) {
}
int copy_tree(const char *from, const char *to, bool merge) {
@@
-360,7
+360,7
@@
int copy_file_fd(const char *from, int fdt, bool try_reflink) {
}
int copy_file(const char *from, const char *to, int flags, mode_t mode, unsigned chattr_flags) {
}
int copy_file(const char *from, const char *to, int flags, mode_t mode, unsigned chattr_flags) {
- int fdt, r;
+ int fdt
= -1
, r;
assert(from);
assert(to);
assert(from);
assert(to);
@@
-372,7
+372,7
@@
int copy_file(const char *from, const char *to, int flags, mode_t mode, unsigned
}
if (chattr_flags != 0)
}
if (chattr_flags != 0)
- (void) chattr_fd(fdt,
true, chattr_flags
);
+ (void) chattr_fd(fdt,
chattr_flags, (unsigned) -1
);
r = copy_file_fd(from, fdt, true);
if (r < 0) {
r = copy_file_fd(from, fdt, true);
if (r < 0) {
@@
-390,13
+390,13
@@
int copy_file(const char *from, const char *to, int flags, mode_t mode, unsigned
}
int copy_file_atomic(const char *from, const char *to, mode_t mode, bool replace, unsigned chattr_flags) {
}
int copy_file_atomic(const char *from, const char *to, mode_t mode, bool replace, unsigned chattr_flags) {
- _cleanup_free_ char *t;
+ _cleanup_free_ char *t
= NULL
;
int r;
assert(from);
assert(to);
int r;
assert(from);
assert(to);
- r = tempfn_random(to, &t);
+ r = tempfn_random(to,
NULL,
&t);
if (r < 0)
return r;
if (r < 0)
return r;
@@
-421,7
+421,7
@@
int copy_file_atomic(const char *from, const char *to, mode_t mode, bool replace
int copy_times(int fdf, int fdt) {
struct timespec ut[2];
struct stat st;
int copy_times(int fdf, int fdt) {
struct timespec ut[2];
struct stat st;
- usec_t crtime;
+ usec_t crtime
= 0
;
assert(fdf >= 0);
assert(fdt >= 0);
assert(fdf >= 0);
assert(fdt >= 0);