mirror of
https://github.com/drakkan/sftpgo.git
synced 2024-11-25 00:50:31 +00:00
sftpd handler: remove eccessive logging and prepare the code to support upload resume
Upload resume is currently disabled for this upstream bug: https://github.com/pkg/sftp/issues/295
This commit is contained in:
parent
c547c5c9ee
commit
88fedd577d
1 changed files with 1 additions and 5 deletions
|
@ -119,8 +119,6 @@ func (c Connection) Filewrite(request *sftp.Request) (io.WriterAt, error) {
|
||||||
|
|
||||||
utils.SetPathPermissions(p, c.User.GetUID(), c.User.GetGID())
|
utils.SetPathPermissions(p, c.User.GetUID(), c.User.GetGID())
|
||||||
|
|
||||||
logger.Debug(logSender, "file upload/replace started for path \"%v\" user: %v", p, c.User.Username)
|
|
||||||
|
|
||||||
transfer := Transfer{
|
transfer := Transfer{
|
||||||
file: file,
|
file: file,
|
||||||
path: p,
|
path: p,
|
||||||
|
@ -175,8 +173,6 @@ func (c Connection) Filewrite(request *sftp.Request) (io.WriterAt, error) {
|
||||||
|
|
||||||
utils.SetPathPermissions(p, c.User.GetUID(), c.User.GetGID())
|
utils.SetPathPermissions(p, c.User.GetUID(), c.User.GetGID())
|
||||||
|
|
||||||
logger.Debug(logSender, "file upload started for path \"%v\" user: %v", p, c.User.Username)
|
|
||||||
|
|
||||||
transfer := Transfer{
|
transfer := Transfer{
|
||||||
file: file,
|
file: file,
|
||||||
path: p,
|
path: p,
|
||||||
|
@ -186,7 +182,7 @@ func (c Connection) Filewrite(request *sftp.Request) (io.WriterAt, error) {
|
||||||
user: c.User,
|
user: c.User,
|
||||||
connectionID: c.ID,
|
connectionID: c.ID,
|
||||||
transferType: transferUpload,
|
transferType: transferUpload,
|
||||||
isNewFile: !trunc,
|
isNewFile: false,
|
||||||
}
|
}
|
||||||
addTransfer(&transfer)
|
addTransfer(&transfer)
|
||||||
return &transfer, nil
|
return &transfer, nil
|
||||||
|
|
Loading…
Reference in a new issue