summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>2001-09-08 13:22:41 +0000
committerJim Meyering <jim@meyering.net>2001-09-08 13:22:41 +0000
commit326aa5c04334723540afa4f7f02086b846f7de45 (patch)
tree2b822b5121665dbfbb7da7e81ff37abc8b792576 /src
parentca01db1efedaacf284357ee2dcd16b23dc718380 (diff)
downloadcoreutils-326aa5c04334723540afa4f7f02086b846f7de45.tar.xz
(copy_internal): Add braces around now-multi-stmt
if-block. This fixes a bug introduced by my 2001-08-06 change.
Diffstat (limited to 'src')
-rw-r--r--src/copy.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/copy.c b/src/copy.c
index 2b2a0da6d..b7f535c7b 100644
--- a/src/copy.c
+++ b/src/copy.c
@@ -696,11 +696,13 @@ copy_internal (const char *src_path, const char *dst_path,
{
overwrite_prompt (dst_path, &dst_sb);
if (!yesno ())
- /* Pretend the rename succeeded, so the caller (mv)
- doesn't end up removing the source file. */
- if (rename_succeeded)
- *rename_succeeded = 1;
- return 0;
+ {
+ /* Pretend the rename succeeded, so the caller (mv)
+ doesn't end up removing the source file. */
+ if (rename_succeeded)
+ *rename_succeeded = 1;
+ return 0;
+ }
}
}
else