aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2014-04-18 17:02:35 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2014-04-18 17:02:35 -0700
commit25bfe4f5f138e07272f98615c305b6f7e56389e2 (patch)
tree301854865a5e539107cec2cee0829bef7a0aa07e /tools
parentMerge tag 'driver-core-3.15-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core (diff)
parentDrivers: hv: vmbus: Negotiate version 3.0 when running on ws2012r2 hosts (diff)
downloadlinux-dev-25bfe4f5f138e07272f98615c305b6f7e56389e2.tar.xz
linux-dev-25bfe4f5f138e07272f98615c305b6f7e56389e2.zip
Merge tag 'char-misc-3.15-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc
Pull char/misc driver fixes from Greg KH: "Here are a few driver fixes for char/misc drivers that resolve reported issues. All have been in linux-next successfully for a few days" * tag 'char-misc-3.15-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc: Drivers: hv: vmbus: Negotiate version 3.0 when running on ws2012r2 hosts Tools: hv: Handle the case when the target file exists correctly vme_tsi148: Utilize to_pci_dev() macro vme_tsi148: Fix PCI address mapping assumption vme_tsi148: Fix typo in tsi148_slave_get() w1: avoid recursive device_add w1: fix netlink refcnt leak on error path misc: Grammar s/addition/additional/ drivers: mcb: fix memory leak in chameleon_parse_cells() error path mei: ignore client writing state during cb completion mei: me: do not load the driver if the FW doesn't support MEI interface GenWQE: Increase driver version number GenWQE: Fix multithreading problems GenWQE: Ensure rc is not returning an uninitialized value GenWQE: Add wmb before DDCB is started GenWQE: Enable access to VPD flash area
Diffstat (limited to 'tools')
-rw-r--r--tools/hv/hv_fcopy_daemon.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/hv/hv_fcopy_daemon.c b/tools/hv/hv_fcopy_daemon.c
index 4ecc4fd0bc1b..fba1c75aa484 100644
--- a/tools/hv/hv_fcopy_daemon.c
+++ b/tools/hv/hv_fcopy_daemon.c
@@ -82,8 +82,10 @@ static int hv_start_fcopy(struct hv_start_fcopy *smsg)
if (!access(target_fname, F_OK)) {
syslog(LOG_INFO, "File: %s exists", target_fname);
- if (!smsg->copy_flags & OVER_WRITE)
+ if (!(smsg->copy_flags & OVER_WRITE)) {
+ error = HV_ERROR_ALREADY_EXISTS;
goto done;
+ }
}
target_fd = open(target_fname, O_RDWR | O_CREAT | O_CLOEXEC, 0744);