Merge lp:~axwalk/juju-core/sshstorage-quote-meta into lp:~go-bot/juju-core/trunk
Proposed by
Andrew Wilkins
Status: | Merged |
---|---|
Approved by: | Andrew Wilkins |
Approved revision: | no longer in the source branch. |
Merged at revision: | 1937 |
Proposed branch: | lp:~axwalk/juju-core/sshstorage-quote-meta |
Merge into: | lp:~go-bot/juju-core/trunk |
Diff against target: |
30 lines (+11/-1) 2 files modified
environs/sshstorage/storage.go (+1/-1) environs/sshstorage/storage_test.go (+10/-0) |
To merge this branch: | bzr merge lp:~axwalk/juju-core/sshstorage-quote-meta |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Tim Penhey (community) | Approve | ||
Review via email:
|
Commit message
environs/
Description of the change
environs/
To post a comment you must log in.
Reviewers: mp+188505_ code.launchpad. net,
Message:
Please take a look.
Description: sshstorage: quote escapes in storage dir
environs/
https:/ /code.launchpad .net/~axwalk/ juju-core/ sshstorage- quote-meta/ +merge/ 188505
(do not edit description out of merge proposal)
Please review this at https:/ /codereview. appspot. com/14195043/
Affected files (+13, -1 lines): sshstorage/ storage. go sshstorage/ storage_ test.go
A [revision details]
M environs/
M environs/
Index: [revision details] 20130930183118- qlwtuzv7j6d2iy7 3
=== added file '[revision details]'
--- [revision details] 2012-01-01 00:00:00 +0000
+++ [revision details] 2012-01-01 00:00:00 +0000
@@ -0,0 +1,2 @@
+Old revision: tarmac-
+New revision: <email address hidden>
Index: environs/ sshstorage/ storage. go sshstorage/ storage. go' sshstorage/ storage. go 2013-09-24 01:55:30 +0000 sshstorage/ storage. go 2013-10-01 03:33:39 +0000 /bin/bash flock %s %s -c %s", s.remotepath) , ShQuote( command) ,
=== modified file 'environs/
--- environs/
+++ environs/
@@ -137,7 +137,7 @@
command = fmt.Sprintf(
"SHELL=
flockmode,
- s.remotepath,
+ utils.ShQuote(
utils.
)
var encoded string
Index: environs/ sshstorage/ storage_ test.go sshstorage/ storage_ test.go' sshstorage/ storage_ test.go 2013-09-23 03:07:31 +0000 sshstorage/ storage_ test.go 2013-10-01 03:33:39 +0000 "example. com", storageDir, Join(tmpdir, "subdir2")) *Permission denied.*") ers(c *gc.C) { Join(storageDir Base, "'") Join(storageDir Base, `"`) os.Mkdir( storageDir, 0755), gc.IsNil) os.Mkdir( tmpdir, 0755), gc.IsNil) "example. com", storageDir, tmpdir)
=== modified file 'environs/
--- environs/
+++ environs/
@@ -341,3 +341,13 @@
_, err := NewSSHStorage(
filepath.
c.Assert(err, gc.ErrorMatches, ".*install: cannot create
directory.
}
+
+func (s *storageSuite) TestPathCharact
+ storageDirBase := c.MkDir()
+ storageDir := filepath.
+ tmpdir := filepath.
+ c.Assert(
+ c.Assert(
+ _, err := NewSSHStorage(
+ c.Assert(err, gc.IsNil)
+}