projects
/
oweals
/
busybox.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d221d21
)
Attempt to make a warning go away without increasing size.
author
Rob Landley
<rob@landley.net>
Tue, 14 Mar 2006 21:13:48 +0000
(21:13 -0000)
committer
Rob Landley
<rob@landley.net>
Tue, 14 Mar 2006 21:13:48 +0000
(21:13 -0000)
libbb/copy_file.c
patch
|
blob
|
history
diff --git
a/libbb/copy_file.c
b/libbb/copy_file.c
index 0763b45863f405cddfa462622d1104e59d28afec..35352d27aecf6a59ff573d90bf144d7674f87f4f 100644
(file)
--- a/
libbb/copy_file.c
+++ b/
libbb/copy_file.c
@@
-165,11
+165,10
@@
int copy_file(const char *source, const char *dest, int flags)
return -1;
}
-
dest_exists = 0
;
+
goto dest_removed
;
}
- }
-
- if (!dest_exists) {
+ } else {
+dest_removed:
dst_fd = open(dest, O_WRONLY|O_CREAT, source_stat.st_mode);
if (dst_fd == -1) {
bb_perror_msg("unable to open `%s'", dest);