Clean the filepath of -ro option.
This fixes problems when using it with a path with trailing slash.
Change-Id: I40abd5379f4d59c2352d95654eb42e11b0949756
diff --git a/cmd/slothfs-populate/main.go b/cmd/slothfs-populate/main.go
index a336ea7..80101b4 100644
--- a/cmd/slothfs-populate/main.go
+++ b/cmd/slothfs-populate/main.go
@@ -281,6 +281,7 @@
// populateCheckout updates a RW dir with new symlinks to the given RO dir.
func populateCheckout(ro, rw string) error {
+ ro = filepath.Clean(ro)
wsName, err := clearLinks(filepath.Dir(ro), rw)
if err != nil {
log.Fatal(err)