The following pull request was submitted through Github.
It can be accessed and reviewed at: https://github.com/lxc/lxd/pull/3292

This e-mail was sent by the LXC bot, direct replies will not reach the author
unless they happen to be subscribed to this list.

=== Description (from pull-request) ===
filepath.Walk() sends filenames with backslashes there

Signed-off-by: anatoly techtonik <[email protected]>
From b454c3d0c3a17f75daf8b4a258e88358e1be4970 Mon Sep 17 00:00:00 2001
From: anatoly techtonik <[email protected]>
Date: Sun, 7 May 2017 13:57:52 +0300
Subject: [PATCH] Fix recursive file push on Windows

filepath.Walk() sends filenames with backslashes there

Signed-off-by: anatoly techtonik <[email protected]>
---
 client.go | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/client.go b/client.go
index c665294..4fbb202 100644
--- a/client.go
+++ b/client.go
@@ -1891,7 +1891,7 @@ func (c *Client) RecursivePushFile(container string, 
source string, target strin
                        appendLen--
                }
 
-               targetPath := path.Join(target, p[appendLen:])
+               targetPath := path.Join(target, filepath.ToSlash(p[appendLen:]))
                if fInfo.IsDir() {
                        mode, uid, gid := shared.GetOwnerMode(fInfo)
                        return c.Mkdir(container, targetPath, mode, uid, gid)
_______________________________________________
lxc-devel mailing list
[email protected]
http://lists.linuxcontainers.org/listinfo/lxc-devel

Reply via email to