|
@@ -166,12 +166,13 @@ func (a aofs) Rename(oldname, newname string) error {
|
|
|
if err != nil {
|
|
|
return err
|
|
|
}
|
|
|
+ defer f.Close()
|
|
|
|
|
|
err = fshdest.FileSystemAbstraction.WriteStream(rewritePathdest, f, 0775)
|
|
|
if err != nil {
|
|
|
return err
|
|
|
}
|
|
|
- f.Close()
|
|
|
+
|
|
|
err = fshsrc.FileSystemAbstraction.RemoveAll(rewritePathsrc)
|
|
|
if err != nil {
|
|
|
return err
|
|
@@ -246,10 +247,12 @@ func (a aofs) pathRewrite(path string) (*filesystem.FileSystemHandler, string, e
|
|
|
return nil, "", errors.New("File System Abstraction not found")
|
|
|
}
|
|
|
|
|
|
- if fsh.RequireBuffer {
|
|
|
- //Not supported
|
|
|
- return nil, "", errors.New("Buffered file system not supported by FTP driver")
|
|
|
- }
|
|
|
+ /*
|
|
|
+ if fsh.RequireBuffer {
|
|
|
+ //Not supported
|
|
|
+ return nil, "", errors.New("Buffered file system not supported by FTP driver")
|
|
|
+ }
|
|
|
+ */
|
|
|
|
|
|
rpath, err := fsh.FileSystemAbstraction.VirtualPathToRealPath(fsh.UUID+":/"+strings.Join(remainingPaths, "/"), a.userinfo.Username)
|
|
|
if err != nil {
|